From 88093597e7f64ae057285f4b06fd05a6c9c98b60 Mon Sep 17 00:00:00 2001 From: Abraham Egnor Date: Fri, 20 May 2022 14:12:08 -0400 Subject: [PATCH] sync tests --- .../unified/change-streams-errors.json | 5 ++ .../unified/change-streams-errors.yml | 5 ++ .../change-streams-pre_and_post_images.json | 5 +- .../change-streams-pre_and_post_images.yml | 3 +- .../change-streams-resume-allowlist.json | 3 +- .../change-streams-resume-allowlist.yml | 4 ++ .../change-streams-resume-errorLabels.json | 3 +- .../change-streams-resume-errorLabels.yml | 4 ++ .../unified/change-streams.json | 65 +++++++------------ .../change-streams/unified/change-streams.yml | 24 +++---- 10 files changed, 61 insertions(+), 60 deletions(-) diff --git a/src/test/spec/json/change-streams/unified/change-streams-errors.json b/src/test/spec/json/change-streams/unified/change-streams-errors.json index c0a9b3f09..04fe8f04f 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-errors.json +++ b/src/test/spec/json/change-streams/unified/change-streams-errors.json @@ -1,6 +1,11 @@ { "description": "change-streams-errors", "schemaVersion": "1.7", + "runOnRequirements": [ + { + "serverless": "forbid" + } + ], "createEntities": [ { "client": { diff --git a/src/test/spec/json/change-streams/unified/change-streams-errors.yml b/src/test/spec/json/change-streams/unified/change-streams-errors.yml index e404922ca..47ad1d07a 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-errors.yml +++ b/src/test/spec/json/change-streams/unified/change-streams-errors.yml @@ -1,5 +1,10 @@ description: "change-streams-errors" + schemaVersion: "1.7" + +runOnRequirements: + - serverless: forbid + createEntities: - client: id: &client0 client0 diff --git a/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.json b/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.json index b6f0e2c3b..8beefb2bc 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.json +++ b/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.json @@ -1,6 +1,6 @@ { "description": "change-streams-pre_and_post_images", - "schemaVersion": "1.0", + "schemaVersion": "1.4", "runOnRequirements": [ { "minServerVersion": "6.0.0", @@ -8,7 +8,8 @@ "replicaset", "sharded-replicaset", "load-balanced" - ] + ], + "serverless": "forbid" } ], "createEntities": [ diff --git a/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.yml b/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.yml index 3dc6afab7..2f6edd982 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.yml +++ b/src/test/spec/json/change-streams/unified/change-streams-pre_and_post_images.yml @@ -1,10 +1,11 @@ description: "change-streams-pre_and_post_images" -schemaVersion: "1.3" +schemaVersion: "1.4" runOnRequirements: - minServerVersion: "6.0.0" topologies: [ replicaset, sharded-replicaset, load-balanced ] + serverless: forbid createEntities: - client: diff --git a/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.json b/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.json index 167f4bb4b..b4953ec73 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.json +++ b/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.json @@ -8,7 +8,8 @@ "replicaset", "sharded-replicaset", "load-balanced" - ] + ], + "serverless": "forbid" } ], "createEntities": [ diff --git a/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.yml b/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.yml index 8b01e03ce..5c69e2301 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.yml +++ b/src/test/spec/json/change-streams/unified/change-streams-resume-allowlist.yml @@ -1,9 +1,13 @@ # Tests for resume behavior on server versions that do not support the ResumableChangeStreamError label description: "change-streams-resume-allowlist" + schemaVersion: "1.7" + runOnRequirements: - minServerVersion: "3.6" topologies: [ replicaset, sharded-replicaset, load-balanced ] + serverless: forbid + createEntities: - client: id: &client0 client0 diff --git a/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.json b/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.json index 68ea30587..c156b550c 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.json +++ b/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.json @@ -8,7 +8,8 @@ "replicaset", "sharded-replicaset", "load-balanced" - ] + ], + "serverless": "forbid" } ], "createEntities": [ diff --git a/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.yml b/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.yml index 7f364de3d..93374598b 100644 --- a/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.yml +++ b/src/test/spec/json/change-streams/unified/change-streams-resume-errorLabels.yml @@ -1,9 +1,13 @@ # Tests for resume behavior on server versions that support the ResumableChangeStreamError label description: "change-streams-resume-errorlabels" + schemaVersion: "1.7" + runOnRequirements: - minServerVersion: "4.3.1" topologies: [ replicaset, sharded-replicaset, load-balanced ] + serverless: forbid + createEntities: - client: id: &client0 client0 diff --git a/src/test/spec/json/change-streams/unified/change-streams.json b/src/test/spec/json/change-streams/unified/change-streams.json index 4faf2c8e0..bec6c9a92 100644 --- a/src/test/spec/json/change-streams/unified/change-streams.json +++ b/src/test/spec/json/change-streams/unified/change-streams.json @@ -5,9 +5,9 @@ { "minServerVersion": "3.6", "topologies": [ - "replicaset", - "sharded-replicaset" - ] + "replicaset" + ], + "serverless": "forbid" } ], "createEntities": [ @@ -273,6 +273,15 @@ }, { "description": "Test new structure in ns document MUST NOT err", + "runOnRequirements": [ + { + "minServerVersion": "3.6", + "maxServerVersion": "5.2.99" + }, + { + "minServerVersion": "6.0" + } + ], "operations": [ { "name": "createChangeStream", @@ -449,10 +458,7 @@ "description": "$changeStream must be the first stage in a change stream pipeline sent to the server", "runOnRequirements": [ { - "minServerVersion": "3.6.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.6.0" } ], "operations": [ @@ -525,10 +531,7 @@ "description": "The server returns change stream responses in the specified server response format", "runOnRequirements": [ { - "minServerVersion": "3.6.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.6.0" } ], "operations": [ @@ -578,10 +581,7 @@ "description": "Executing a watch helper on a Collection results in notifications for changes to the specified collection", "runOnRequirements": [ { - "minServerVersion": "3.6.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.6.0" } ], "operations": [ @@ -666,10 +666,7 @@ "description": "Change Stream should allow valid aggregate pipeline stages", "runOnRequirements": [ { - "minServerVersion": "3.6.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.6.0" } ], "operations": [ @@ -756,10 +753,7 @@ "description": "Executing a watch helper on a Database results in notifications for changes to all collections in the specified database.", "runOnRequirements": [ { - "minServerVersion": "3.8.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.8.0" } ], "operations": [ @@ -861,10 +855,7 @@ "description": "Executing a watch helper on a MongoClient results in notifications for changes to all collections in all databases in the cluster.", "runOnRequirements": [ { - "minServerVersion": "3.8.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.8.0" } ], "operations": [ @@ -985,10 +976,7 @@ "description": "Test insert, update, replace, and delete event types", "runOnRequirements": [ { - "minServerVersion": "3.6.0", - "topologies": [ - "replicaset" - ] + "minServerVersion": "3.6.0" } ], "operations": [ @@ -1140,10 +1128,7 @@ "description": "Test rename and invalidate event types", "runOnRequirements": [ { - "minServerVersion": "4.0.1", - "topologies": [ - "replicaset" - ] + "minServerVersion": "4.0.1" } ], "operations": [ @@ -1220,10 +1205,7 @@ "description": "Test drop and invalidate event types", "runOnRequirements": [ { - "minServerVersion": "4.0.1", - "topologies": [ - "replicaset" - ] + "minServerVersion": "4.0.1" } ], "operations": [ @@ -1289,10 +1271,7 @@ "description": "Test consecutive resume", "runOnRequirements": [ { - "minServerVersion": "4.1.7", - "topologies": [ - "replicaset" - ] + "minServerVersion": "4.1.7" } ], "operations": [ diff --git a/src/test/spec/json/change-streams/unified/change-streams.yml b/src/test/spec/json/change-streams/unified/change-streams.yml index afaa77ca7..3dfe825ff 100644 --- a/src/test/spec/json/change-streams/unified/change-streams.yml +++ b/src/test/spec/json/change-streams/unified/change-streams.yml @@ -1,8 +1,14 @@ description: "change-streams" + schemaVersion: "1.7" + runOnRequirements: - minServerVersion: "3.6" - topologies: [ replicaset, sharded-replicaset ] + # TODO(DRIVERS-2323): Run all possible tests against sharded clusters once we know the + # cause of unexpected command monitoring events. + topologies: [ replicaset ] + serverless: forbid + createEntities: - client: id: &client0 client0 @@ -155,6 +161,10 @@ tests: newField: "newFieldValue" - description: "Test new structure in ns document MUST NOT err" + runOnRequirements: + - minServerVersion: "3.6" + maxServerVersion: "5.2.99" + - minServerVersion: "6.0" operations: - name: createChangeStream object: *collection0 @@ -238,7 +248,6 @@ tests: - description: $changeStream must be the first stage in a change stream pipeline sent to the server runOnRequirements: - minServerVersion: "3.6.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -275,7 +284,6 @@ tests: - description: The server returns change stream responses in the specified server response format runOnRequirements: - minServerVersion: "3.6.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -301,7 +309,6 @@ tests: - description: Executing a watch helper on a Collection results in notifications for changes to the specified collection runOnRequirements: - minServerVersion: "3.6.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -344,7 +351,6 @@ tests: - description: Change Stream should allow valid aggregate pipeline stages runOnRequirements: - minServerVersion: "3.6.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -389,7 +395,6 @@ tests: - description: Executing a watch helper on a Database results in notifications for changes to all collections in the specified database. runOnRequirements: - minServerVersion: "3.8.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *database0 @@ -442,7 +447,6 @@ tests: - description: Executing a watch helper on a MongoClient results in notifications for changes to all collections in all databases in the cluster. runOnRequirements: - minServerVersion: "3.8.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *client0 @@ -506,7 +510,6 @@ tests: - description: "Test insert, update, replace, and delete event types" runOnRequirements: - minServerVersion: "3.6.0" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -584,7 +587,6 @@ tests: - description: Test rename and invalidate event types runOnRequirements: - minServerVersion: "4.0.1" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -627,7 +629,6 @@ tests: - description: Test drop and invalidate event types runOnRequirements: - minServerVersion: "4.0.1" - topologies: [ replicaset ] operations: - name: createChangeStream object: *collection0 @@ -661,11 +662,10 @@ tests: databaseName: *database0 # Test that resume logic works correctly even after consecutive retryable failures of a getMore command, - # with no intervening events. This is ensured by setting the batch size of the change stream to 1, + # with no intervening events. This is ensured by setting the batch size of the change stream to 1, - description: Test consecutive resume runOnRequirements: - minServerVersion: "4.1.7" - topologies: [ replicaset ] operations: - name: failPoint object: testRunner