Skip to content

Commit

Permalink
chore: sync retryable reads tests for listIndex changes
Browse files Browse the repository at this point in the history
  • Loading branch information
mbroadst committed Jul 10, 2020
1 parent d50ab53 commit eff550d
Show file tree
Hide file tree
Showing 17 changed files with 84 additions and 233 deletions.
8 changes: 7 additions & 1 deletion test/spec/retryable-reads/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,10 @@ Each YAML file has the following keys:
- ``bucket_name``: Optional. The GridFS bucket name to use for testing.

- ``data``: The data that should exist in the collection(s) under test before
each test run.
each test run. This will typically be an array of documents to be inserted
into the collection under test (i.e. ``collection_name``); however, this field
may also be an object mapping collection names to arrays of documents to be
inserted into the specified collection.

- ``tests``: An array of tests that are to be run independently of each other.
Each test will have some or all of the following fields:
Expand Down Expand Up @@ -126,6 +129,9 @@ GridFS Tests
------------

GridFS tests are denoted by when the YAML file contains ``bucket_name``.
The ``data`` field will also be an object, which maps collection names
(e.g. ``fs.files``) to an array of documents that should be inserted into
the specified collection.

``fs.files`` and ``fs.chunks`` should be created in the database
specified by ``database_name``. This could be done via inserts or by
Expand Down
2 changes: 1 addition & 1 deletion test/spec/retryable-reads/aggregate-merge.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"runOn": [
{
"minServerVersion": "4.2.0"
"minServerVersion": "4.1.11"
}
],
"database_name": "retryable-reads-tests",
Expand Down
2 changes: 1 addition & 1 deletion test/spec/retryable-reads/aggregate-merge.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
runOn:
-
minServerVersion: "4.2.0"
minServerVersion: "4.1.11"

database_name: &database_name "retryable-reads-tests"
collection_name: &collection_name "coll"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -76,7 +75,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -116,7 +114,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -133,7 +130,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -173,7 +169,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -190,7 +185,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -230,7 +224,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -247,7 +240,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -287,7 +279,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -304,7 +295,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -344,7 +334,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -361,7 +350,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -401,7 +389,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -418,7 +405,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -458,7 +444,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -475,7 +460,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -515,7 +499,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -532,7 +515,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -572,7 +554,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -589,7 +570,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -629,7 +609,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -646,7 +625,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -687,7 +665,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -704,7 +681,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -748,7 +724,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ tests:
command:
aggregate: 1
cursor: {}
pipeline: [ { $changeStream: { fullDocument: "default", allChangesForCluster: true } } ]
pipeline: [ { $changeStream: { allChangesForCluster: true } } ]
database_name: admin
- *retryable_command_started_event
-
Expand Down
6 changes: 0 additions & 6 deletions test/spec/retryable-reads/changeStreams-client.watch.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -79,7 +78,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -96,7 +94,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -140,7 +137,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down Expand Up @@ -181,7 +177,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand All @@ -198,7 +193,6 @@
"pipeline": [
{
"$changeStream": {
"fullDocument": "default",
"allChangesForCluster": true
}
}
Expand Down
2 changes: 1 addition & 1 deletion test/spec/retryable-reads/changeStreams-client.watch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ tests:
command:
aggregate: 1
cursor: {}
pipeline: [ { $changeStream: { fullDocument: "default", "allChangesForCluster": true } } ]
pipeline: [ { $changeStream: { "allChangesForCluster": true } } ]
database_name: admin
-
description: "client.watch succeeds on second attempt"
Expand Down
Loading

0 comments on commit eff550d

Please sign in to comment.