Skip to content

Commit

Permalink
Fix nodes.info yaml rest test during mixedclustertest
Browse files Browse the repository at this point in the history
Signed-off-by: Tianli Feng <[email protected]>
  • Loading branch information
Tianli Feng committed Mar 14, 2022
1 parent cf385f5 commit fb7ec1a
Showing 1 changed file with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,20 @@
---
"Test cat nodes output - before 2.0.0":
- skip:
version: " 2.0.0 - "
version: "2.0.0 - "
reason: "master is replaced by cluster_manager in 2.0.0"
features: node_selector

- do:
cat.nodes:
v: true
node_selector:
# Only send request to nodes in <2.0 versions, especially during ':qa:mixed-cluster:v1.x.x#mixedClusterTest'.
# Because YAML REST test takes the minimum OpenSearch version in the cluster to apply the filter in 'skip' section,
# see OpenSearchClientYamlSuiteTestCase#initAndResetContext() for detail.
# During 'mixedClusterTest', the cluster can be mixed with nodes in 1.x and 2.x versions,
# so node_selector is required, and only filtering version in 'skip' is not enough.
version: "1.0.0 - 1.4.99"

- match:
$body: |
Expand All @@ -18,12 +26,9 @@
- skip:
version: " - 1.4.99"
reason: "cluster_manager is introduced in 2.0.0"
features: node_selector

- do:
cat.nodes: {}
node_selector:
version: "2.0.0 - " # Only send request to nodes in 2.x versions, especially during mixedClusterTest.

- match:
$body: |
Expand Down

0 comments on commit fb7ec1a

Please sign in to comment.