Skip to content

Commit 4d11668

Browse files
authored
DRIVERS-3390 Add appName to OIDC test failpoints (#1891)
To address inconsistent observed failures running OIDC tests on GCP.
1 parent 434f5d6 commit 4d11668

File tree

3 files changed

+21
-9
lines changed

3 files changed

+21
-9
lines changed

source/auth/tests/mongodb-oidc.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ Drivers MUST implement all prose tests in this section. Unless otherwise noted,
3535
configured with `retryReads=false`.
3636

3737
> [!NOTE]
38-
> For test cases that create fail points, drivers MUST either use a unique `appName` or explicitly remove the fail point
39-
> callback to prevent interaction between test cases.
38+
> For test cases that create fail points, drivers MUST use a unique `appName` to prevent interaction with other
39+
> environment processes, and explicitly remove the fail point to prevent interaction between test runs.
4040
4141
After setting up your OIDC
4242
[environment](https://github.com/mongodb-labs/drivers-evergreen-tools/blob/master/.evergreen/auth_oidc/README.md),

source/auth/tests/unified/mongodb-oidc-no-retry.json

Lines changed: 12 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

source/auth/tests/unified/mongodb-oidc-no-retry.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ createEntities:
2121
authMechanismProperties: { $$placeholder: 1 }
2222
retryReads: false
2323
retryWrites: false
24+
appName: &appName mongodb-oidc-no-retry
2425
observeEvents:
2526
- commandStartedEvent
2627
- commandSucceededEvent
@@ -87,6 +88,7 @@ tests:
8788
failCommands:
8889
- find
8990
errorCode: 391 # ReauthenticationRequired
91+
appName: *appName
9092
- name: find
9193
object: collection0
9294
arguments:
@@ -121,6 +123,7 @@ tests:
121123
failCommands:
122124
- insert
123125
errorCode: 391 # ReauthenticationRequired
126+
appName: *appName
124127
- name: insertOne
125128
object: collection0
126129
arguments:
@@ -160,6 +163,7 @@ tests:
160163
failCommands:
161164
- insert
162165
closeConnection: true
166+
appName: *appName
163167
- name: insertOne
164168
object: collection0
165169
arguments:
@@ -180,6 +184,7 @@ tests:
180184
failCommands:
181185
- saslStart
182186
errorCode: 18
187+
appName: *appName
183188
- name: insertOne
184189
object: collection0
185190
arguments:
@@ -219,11 +224,12 @@ tests:
219224
failCommands:
220225
- saslStart
221226
errorCode: 18
227+
appName: *appName
222228
- name: insertOne
223229
object: collection0
224230
arguments:
225231
document:
226232
_id: 1
227233
x: 1
228234
expectError:
229-
errorCode: 18
235+
errorCode: 18

0 commit comments

Comments
 (0)