Skip to content

Commit c11aef8

Browse files
committed
add more details to tests
1 parent 42e4d94 commit c11aef8

File tree

1 file changed

+17
-2
lines changed
  • source/transactions-convenient-api/tests

1 file changed

+17
-2
lines changed

source/transactions-convenient-api/tests/README.md

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,23 @@ private API or using a mock timer.
4444
### Retry Backoff is Enforced
4545

4646
Drivers should test that retries within `withTransaction` do not occur immediately. Optionally, set BACKOFF_INITIAL to a
47-
higher value to decrease flakiness of this test. Configure a fail point that forces 30 retries. Check that the total
48-
time for all retries exceeded 1.25 seconds.
47+
higher value to decrease flakiness of this test. Configure a fail point that forces 30 retries like so:
48+
49+
```json
50+
{
51+
"configureFailPoint": "failCommand",
52+
"mode": {
53+
"times": 30
54+
},
55+
"data": {
56+
"failCommands": ["commitTransaction"],
57+
"errorCode": 24,
58+
},
59+
}
60+
```
61+
62+
Additionally, let the callback for the transaction be a simple `insertOne` command. Check that the total time for all
63+
retries exceeded 1.25 seconds.
4964

5065
## Changelog
5166

0 commit comments

Comments
 (0)