Skip to content

Commit 068eae5

Browse files
committed
[CI] Test Runner: Adds node_selector to skipped features in YAML test runner
1 parent 1dd46b1 commit 068eae5

File tree

3 files changed

+6
-10
lines changed

3 files changed

+6
-10
lines changed

api-spec-testing/test_file/test.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,8 @@ def skip_test?(client, features_to_skip = test_file.features_to_skip)
219219
return true if pre_defined_skip?
220220

221221
if @skip
222-
@skip.collect { |s| s['skip'] }.any? do |skip|
223-
contains_features_to_skip?(features_to_skip, skip) || test_file.skip_version?(client, skip)
222+
@skip.collect { |s| s['skip'] }.any? do |skip_definition|
223+
contains_features_to_skip?(features_to_skip, skip_definition) || test_file.skip_version?(client, skip_definition)
224224
end
225225
end
226226
end
@@ -244,8 +244,8 @@ def inject_master_node_id(expected_key)
244244

245245
private
246246

247-
def contains_features_to_skip?(features_to_skip, skip_defintion)
248-
!(features_to_skip & ([skip_defintion['features']].flatten || [])).empty?
247+
def contains_features_to_skip?(features_to_skip, skip_definition)
248+
!(features_to_skip & ([skip_definition['features']].flatten || [])).empty?
249249
end
250250

251251
def pre_defined_skip?

elasticsearch-api/spec/rest_yaml_tests_helper.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,6 @@
9494
skipped_tests << { file: 'cat.templates/10_basic.yml',
9595
description: '*' }
9696

97-
# node_selector is not supported yet
98-
skipped_tests << { file: 'cat.aliases/10_basic.yml',
99-
description: '*' }
100-
10197
# Responses are there but not equal (eg.: yellow status)
10298
skipped_tests << { file: 'cluster.health/10_basic.yml',
10399
description: 'cluster health with closed index (pre 7.2.0)' }
@@ -112,4 +108,4 @@
112108
REST_API_YAML_FILES = SINGLE_TEST || Dir.glob("#{YAML_FILES_DIRECTORY}/**/*.yml")
113109

114110
# The features to skip
115-
REST_API_YAML_SKIP_FEATURES = ['warnings'].freeze
111+
REST_API_YAML_SKIP_FEATURES = ['warnings', 'node_selector'].freeze

elasticsearch-xpack/spec/rest_yaml_tests_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,4 +188,4 @@
188188
REST_API_YAML_FILES = SINGLE_TEST || Dir.glob("#{YAML_FILES_DIRECTORY}/**/*.yml")
189189

190190
# The features to skip
191-
REST_API_YAML_SKIP_FEATURES = ['warnings'].freeze
191+
REST_API_YAML_SKIP_FEATURES = ['warnings', 'node_selector'].freeze

0 commit comments

Comments
 (0)