diff options
Diffstat (limited to 'spec/support/helpers/expect_request_with_status.rb')
-rw-r--r-- | spec/support/helpers/expect_request_with_status.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/spec/support/helpers/expect_request_with_status.rb b/spec/support/helpers/expect_request_with_status.rb new file mode 100644 index 00000000000..0469a94e336 --- /dev/null +++ b/spec/support/helpers/expect_request_with_status.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +module ExpectRequestWithStatus + def expect_request_with_status(status) + expect do + yield + + expect(response).to have_gitlab_http_status(status) + end + end +end |