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.
3433 isError : true
35- errorContains : Atlas
34+ errorContains : Search index commands are only supported with Atlas
3635 expectEvents :
3736 - client : *client0
3837 events :
@@ -48,61 +47,37 @@ tests:
4847 - name : createSearchIndexes
4948 object : *collection0
5049 arguments :
51- models : [ { definition: &definition { mappings: { dynamic: true } } , type: 'search' } ]
50+ models : [ { definition: &definition { mappings: { dynamic: true } } } ]
5251 expectError :
5352 # This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
5453 # 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.
5654 isError : true
57- errorContains : Atlas
55+ errorContains : Search index commands are only supported with Atlas
5856 expectEvents :
5957 - client : *client0
6058 events :
6159 - commandStartedEvent :
6260 command :
6361 createSearchIndexes : *collection0
64- indexes : [ { definition: *definition, type: 'search' } ]
62+ indexes : [ { definition: *definition } ]
6563 $db : *database0
6664
6765 - description : " name provided for an index definition"
6866 operations :
6967 - name : createSearchIndexes
7068 object : *collection0
7169 arguments :
72- models : [ { definition: &definition { mappings: { dynamic: true } } , name: 'test index' , type: 'search' } ]
70+ models : [ { definition: &definition { mappings: { dynamic: true } } , name: 'test index' } ]
7371 expectError :
7472 # This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
7573 # 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.
7774 isError : true
78- errorContains : Atlas
75+ errorContains : Search index commands are only supported with Atlas
7976 expectEvents :
8077 - client : *client0
8178 events :
8279 - commandStartedEvent :
8380 command :
8481 createSearchIndexes : *collection0
85- indexes : [ { definition: *definition, name: 'test index', type: 'search' } ]
86- $db : *database0
87-
88- - description : " create a vector search index"
89- operations :
90- - name : createSearchIndexes
91- object : *collection0
92- arguments :
93- models : [ { definition: &definition { fields: [ {"type": "vector", "path": "plot_embedding", "numDimensions": 1536, "similarity": "euclidean"} ] },
94- name : ' test index' , type: 'vectorSearch' } ]
95- expectError :
96- # This test always errors in a non-Atlas environment. The test functions as a unit test by asserting
97- # that the driver constructs and sends the correct command.
98- # The expected error message was changed in SERVER-83003. Check for the substring "Atlas" shared by both error messages.
99- isError : true
100- errorContains : Atlas
101- expectEvents :
102- - client : *client0
103- events :
104- - commandStartedEvent :
105- command :
106- createSearchIndexes : *collection0
107- indexes : [ { definition: *definition, name: 'test index', type: 'vectorSearch' } ]
82+ indexes : [ { definition: *definition, name: 'test index' } ]
10883 $db : *database0
0 commit comments