Skip to content

Commit f18c409

Browse files
authored
RUBY-3362 sync specs to fix failing tests on server version 7.3 (#2819)
1 parent d75a422 commit f18c409

File tree

5 files changed

+23
-13
lines changed

5 files changed

+23
-13
lines changed

Diff for: spec/spec_tests/data/index_management/createSearchIndex.yml

+5-3
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ tests:
3030
expectError:
3131
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
3232
# that the driver constructs and sends the correct command.
33+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
3334
isError: true
34-
errorContains: Search index commands are only supported with Atlas
35+
errorContains: Atlas
3536
expectEvents:
3637
- client: *client0
3738
events:
@@ -50,13 +51,14 @@ tests:
5051
expectError:
5152
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
5253
# that the driver constructs and sends the correct command.
54+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
5355
isError: true
54-
errorContains: Search index commands are only supported with Atlas
56+
errorContains: Atlas
5557
expectEvents:
5658
- client: *client0
5759
events:
5860
- commandStartedEvent:
5961
command:
6062
createSearchIndexes: *collection0
6163
indexes: [ { definition: *definition, name: 'test index' } ]
62-
$db: *database0
64+
$db: *database0

Diff for: spec/spec_tests/data/index_management/createSearchIndexes.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ tests:
3030
expectError:
3131
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
3232
# that the driver constructs and sends the correct command.
33+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
3334
isError: true
34-
errorContains: Search index commands are only supported with Atlas
35+
errorContains: Atlas
3536
expectEvents:
3637
- client: *client0
3738
events:
@@ -51,8 +52,9 @@ tests:
5152
expectError:
5253
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
5354
# that the driver constructs and sends the correct command.
55+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
5456
isError: true
55-
errorContains: Search index commands are only supported with Atlas
57+
errorContains: Atlas
5658
expectEvents:
5759
- client: *client0
5860
events:
@@ -71,13 +73,14 @@ tests:
7173
expectError:
7274
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
7375
# that the driver constructs and sends the correct command.
76+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
7477
isError: true
75-
errorContains: Search index commands are only supported with Atlas
78+
errorContains: Atlas
7679
expectEvents:
7780
- client: *client0
7881
events:
7982
- commandStartedEvent:
8083
command:
8184
createSearchIndexes: *collection0
8285
indexes: [ { definition: *definition, name: 'test index' } ]
83-
$db: *database0
86+
$db: *database0

Diff for: spec/spec_tests/data/index_management/dropSearchIndex.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ tests:
3030
expectError:
3131
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
3232
# that the driver constructs and sends the correct command.
33+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
3334
isError: true
34-
errorContains: Search index commands are only supported with Atlas
35+
errorContains: Atlas
3536
expectEvents:
3637
- client: *client0
3738
events:

Diff for: spec/spec_tests/data/index_management/listSearchIndexes.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,9 @@ tests:
2828
expectError:
2929
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
3030
# that the driver constructs and sends the correct command.
31+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
3132
isError: true
32-
errorContains: Search index commands are only supported with Atlas
33+
errorContains: Atlas
3334
expectEvents:
3435
- client: *client0
3536
events:
@@ -48,8 +49,9 @@ tests:
4849
expectError:
4950
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
5051
# that the driver constructs and sends the correct command.
52+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
5153
isError: true
52-
errorContains: Search index commands are only supported with Atlas
54+
errorContains: Atlas
5355
expectEvents:
5456
- client: *client0
5557
events:
@@ -71,8 +73,9 @@ tests:
7173
expectError:
7274
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
7375
# that the driver constructs and sends the correct command.
76+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
7477
isError: true
75-
errorContains: Search index commands are only supported with Atlas
78+
errorContains: Atlas
7679
expectEvents:
7780
- client: *client0
7881
events:
@@ -82,4 +85,4 @@ tests:
8285
cursor: { batchSize: 10 }
8386
pipeline:
8487
- $listSearchIndexes: { name: *indexName }
85-
$db: *database0
88+
$db: *database0

Diff for: spec/spec_tests/data/index_management/updateSearchIndex.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,9 @@ tests:
3131
expectError:
3232
# This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
3333
# that the driver constructs and sends the correct command.
34+
# The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
3435
isError: true
35-
errorContains: Search index commands are only supported with Atlas
36+
errorContains: Atlas
3637
expectEvents:
3738
- client: *client0
3839
events:

0 commit comments

Comments
 (0)