15 lines
378 B
Ruby
15 lines
378 B
Ruby
require_relative './wait_for_requests'
|
|
|
|
module InspectRequests
|
|
extend self
|
|
include WaitForRequests
|
|
|
|
def inspect_requests
|
|
Gitlab::Testing::RequestInspectorMiddleware.log_requests!
|
|
yield
|
|
block_and_wait_for_requests_complete
|
|
Gitlab::Testing::RequestInspectorMiddleware.requests
|
|
ensure
|
|
Gitlab::Testing::RequestInspectorMiddleware.stop_logging!
|
|
end
|
|
end
|