Skip to content

Commit a8812ec

Browse files
committed
test: skip http tests failing on old rubies
1 parent 21a4b15 commit a8812ec

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

features/open_api.feature

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
@ruby27_required
12
Feature: Generate Open API Specification from test examples
23

34
Background:

features/support/env.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,9 @@
99
config.match = :prefer_exact
1010
config.ignore_hidden_elements = false
1111
end
12+
13+
Before('@ruby27_required') do |scenario|
14+
if RUBY_VERSION < '2.7'
15+
raise Cucumber::Pending, "Skipped on Ruby #{RUBY_VERSION} (requires >= 2.7)"
16+
end
17+
end

spec/http_test_client_spec.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77

88
describe RspecApiDocumentation::HttpTestClient do
99
before(:all) do
10+
if RUBY_VERSION < '2.7'
11+
skip("Skipped on Ruby #{RUBY_VERSION} (requires >= 2.7)")
12+
end
1013
WebMock.allow_net_connect!
1114
# Capybara.server= was introduced in later versions
1215
# For older versions, we use the Capybara::Server directly with webrick

0 commit comments

Comments
 (0)