Skip to content

Commit 0a578b4

Browse files
authored
PYTHON-4396 Unskip failCommand+appName tests on MongoDB 4.4.7+ (mongodb#1735)
1 parent f17f5e2 commit 0a578b4

27 files changed

+204
-100
lines changed

test/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -728,9 +728,9 @@ def require_failCommand_fail_point(self, func):
728728

729729
def require_failCommand_appName(self, func):
730730
"""Run a test only if the server supports the failCommand appName."""
731-
# SERVER-47195
731+
# SERVER-47195 and SERVER-49336.
732732
return self._require(
733-
lambda: (self.test_commands_enabled and self.version >= (4, 4, -1)),
733+
lambda: (self.test_commands_enabled and self.version >= (4, 4, 7)),
734734
"failCommand appName must be supported",
735735
func=func,
736736
)

test/asynchronous/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -730,9 +730,9 @@ def require_failCommand_fail_point(self, func):
730730

731731
def require_failCommand_appName(self, func):
732732
"""Run a test only if the server supports the failCommand appName."""
733-
# SERVER-47195
733+
# SERVER-47195 and SERVER-49336.
734734
return self._require(
735-
lambda: (self.test_commands_enabled and self.version >= (4, 4, -1)),
735+
lambda: (self.test_commands_enabled and self.version >= (4, 4, 7)),
736736
"failCommand appName must be supported",
737737
func=func,
738738
)

test/csot/change-streams.json

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"minServerVersion": "4.4",
77
"topologies": [
88
"replicaset",
9-
"sharded-replicaset"
9+
"sharded"
1010
]
1111
}
1212
],
@@ -104,7 +104,7 @@
104104
"aggregate"
105105
],
106106
"blockConnection": true,
107-
"blockTimeMS": 55
107+
"blockTimeMS": 250
108108
}
109109
}
110110
}
@@ -114,7 +114,7 @@
114114
"object": "collection",
115115
"arguments": {
116116
"pipeline": [],
117-
"timeoutMS": 50
117+
"timeoutMS": 200
118118
},
119119
"expectError": {
120120
"isTimeoutError": true
@@ -242,7 +242,7 @@
242242
"getMore"
243243
],
244244
"blockConnection": true,
245-
"blockTimeMS": 15
245+
"blockTimeMS": 150
246246
}
247247
}
248248
}
@@ -252,7 +252,7 @@
252252
"object": "collection",
253253
"arguments": {
254254
"pipeline": [],
255-
"timeoutMS": 20,
255+
"timeoutMS": 200,
256256
"batchSize": 2,
257257
"maxAwaitTimeMS": 1
258258
},
@@ -310,7 +310,7 @@
310310
"object": "collection",
311311
"arguments": {
312312
"pipeline": [],
313-
"timeoutMS": 20
313+
"timeoutMS": 200
314314
},
315315
"saveResultAsEntity": "changeStream"
316316
},
@@ -330,7 +330,7 @@
330330
"aggregate"
331331
],
332332
"blockConnection": true,
333-
"blockTimeMS": 12,
333+
"blockTimeMS": 120,
334334
"errorCode": 7,
335335
"errorLabels": [
336336
"ResumableChangeStreamError"
@@ -412,7 +412,7 @@
412412
"arguments": {
413413
"pipeline": [],
414414
"maxAwaitTimeMS": 1,
415-
"timeoutMS": 100
415+
"timeoutMS": 200
416416
},
417417
"saveResultAsEntity": "changeStream"
418418
},
@@ -431,7 +431,7 @@
431431
"getMore"
432432
],
433433
"blockConnection": true,
434-
"blockTimeMS": 150
434+
"blockTimeMS": 250
435435
}
436436
}
437437
}
@@ -534,7 +534,7 @@
534534
"getMore"
535535
],
536536
"blockConnection": true,
537-
"blockTimeMS": 15
537+
"blockTimeMS": 250
538538
}
539539
}
540540
}
@@ -544,7 +544,7 @@
544544
"object": "collection",
545545
"arguments": {
546546
"pipeline": [],
547-
"timeoutMS": 10
547+
"timeoutMS": 200
548548
},
549549
"saveResultAsEntity": "changeStream"
550550
},

test/csot/close-cursors.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
"getMore"
7676
],
7777
"blockConnection": true,
78-
"blockTimeMS": 50
78+
"blockTimeMS": 250
7979
}
8080
}
8181
}
@@ -86,7 +86,7 @@
8686
"arguments": {
8787
"filter": {},
8888
"batchSize": 2,
89-
"timeoutMS": 20
89+
"timeoutMS": 200
9090
},
9191
"saveResultAsEntity": "cursor"
9292
},
@@ -175,7 +175,7 @@
175175
"killCursors"
176176
],
177177
"blockConnection": true,
178-
"blockTimeMS": 30
178+
"blockTimeMS": 250
179179
}
180180
}
181181
}
@@ -186,15 +186,15 @@
186186
"arguments": {
187187
"filter": {},
188188
"batchSize": 2,
189-
"timeoutMS": 20
189+
"timeoutMS": 200
190190
},
191191
"saveResultAsEntity": "cursor"
192192
},
193193
{
194194
"name": "close",
195195
"object": "cursor",
196196
"arguments": {
197-
"timeoutMS": 40
197+
"timeoutMS": 400
198198
}
199199
}
200200
],
@@ -215,7 +215,7 @@
215215
{
216216
"commandStartedEvent": {
217217
"command": {
218-
"killCursors": "collection",
218+
"killCursors": "coll",
219219
"maxTimeMS": {
220220
"$$type": [
221221
"int",

test/csot/command-execution.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@
33
"schemaVersion": "1.9",
44
"runOnRequirements": [
55
{
6-
"minServerVersion": "4.9",
6+
"minServerVersion": "4.4.7",
77
"topologies": [
88
"single",
99
"replicaset",
10-
"sharded-replicaset",
1110
"sharded"
1211
],
1312
"serverless": "forbid"
@@ -52,7 +51,7 @@
5251
],
5352
"appName": "reduceMaxTimeMSTest",
5453
"blockConnection": true,
55-
"blockTimeMS": 75
54+
"blockTimeMS": 50
5655
}
5756
}
5857
}

test/csot/convenient-transactions.json

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"minServerVersion": "4.4",
77
"topologies": [
88
"replicaset",
9-
"sharded-replicaset"
9+
"sharded"
1010
]
1111
}
1212
],
@@ -21,7 +21,7 @@
2121
"client": {
2222
"id": "client",
2323
"uriOptions": {
24-
"timeoutMS": 50
24+
"timeoutMS": 500
2525
},
2626
"useMultipleMongoses": false,
2727
"observeEvents": [
@@ -81,6 +81,9 @@
8181
}
8282
}
8383
]
84+
},
85+
"expectError": {
86+
"isClientError": true
8487
}
8588
}
8689
],
@@ -109,7 +112,7 @@
109112
"insert"
110113
],
111114
"blockConnection": true,
112-
"blockTimeMS": 30
115+
"blockTimeMS": 300
113116
}
114117
}
115118
}
@@ -182,6 +185,21 @@
182185
}
183186
}
184187
}
188+
},
189+
{
190+
"commandStartedEvent": {
191+
"commandName": "abortTransaction",
192+
"databaseName": "admin",
193+
"command": {
194+
"abortTransaction": 1,
195+
"maxTimeMS": {
196+
"$$type": [
197+
"int",
198+
"long"
199+
]
200+
}
201+
}
202+
}
185203
}
186204
]
187205
}

test/csot/deprecated-options.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"minServerVersion": "4.2",
77
"topologies": [
88
"replicaset",
9-
"sharded-replicaset"
9+
"sharded"
1010
]
1111
}
1212
],

test/csot/error-transformations.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
{
1212
"minServerVersion": "4.2",
1313
"topologies": [
14-
"replicaset",
1514
"sharded"
1615
]
1716
}

test/csot/global-timeoutMS.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"minServerVersion": "4.4",
77
"topologies": [
88
"replicaset",
9-
"sharded-replicaset"
9+
"sharded"
1010
]
1111
}
1212
],

test/csot/legacy-timeouts.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"description": "legacy timeouts continue to work if timeoutMS is not set",
3-
"schemaVersion": "1.9",
3+
"schemaVersion": "1.0",
44
"runOnRequirements": [
55
{
66
"minServerVersion": "4.4"
@@ -280,7 +280,7 @@
280280
{
281281
"topologies": [
282282
"replicaset",
283-
"sharded-replicaset"
283+
"sharded"
284284
]
285285
}
286286
],

0 commit comments

Comments
 (0)