Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-10-23 15:57:06 +0300
committerMike Greiling <mike@pixelcog.com>2017-10-23 17:00:42 +0300
commita92693df7742214a44caa521f9be7ab52f99d6b6 (patch)
tree859a970ec67d55078a3a53af225aadf08f026363 /lib/gitlab/testing
parentb612bcfc64618906b5b11a245fb0aa2452d6c5dd (diff)
add InspectRequests helper
Diffstat (limited to 'lib/gitlab/testing')
-rw-r--r--lib/gitlab/testing/request_inspector_middleware.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/gitlab/testing/request_inspector_middleware.rb b/lib/gitlab/testing/request_inspector_middleware.rb
index 0ca21bd6a37..ff5bf9d74f4 100644
--- a/lib/gitlab/testing/request_inspector_middleware.rb
+++ b/lib/gitlab/testing/request_inspector_middleware.rb
@@ -30,12 +30,12 @@ module Gitlab
request_headers = env_http_headers(env)
status, headers, body = @app.call(env)
- log_response({
+ log_response(OpenStruct.new(
url: url,
status_code: status,
request_headers: request_headers,
response_headers: headers
- })
+ ))
[status, headers, body]
end
@@ -52,7 +52,6 @@ module Gitlab
def log_response(response)
@@logged_requests.push(response)
- STDOUT.puts response.to_json
end
end
end