From a386623766be5a9d2fb1b03d1f585482f62d82a4 Mon Sep 17 00:00:00 2001 From: Jeremy Mikola Date: Wed, 14 Feb 2024 14:44:07 -0500 Subject: [PATCH] Callback operation errors should always propagate to withTransaction --- source/unified-test-format/unified-test-format.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/source/unified-test-format/unified-test-format.md b/source/unified-test-format/unified-test-format.md index ef7aa34bba..7807ec4adb 100644 --- a/source/unified-test-format/unified-test-format.md +++ b/source/unified-test-format/unified-test-format.md @@ -1706,6 +1706,11 @@ testing, this parameter is expressed as an array of [operation](#operation) obje [test.operations](#test_operations)). Test runners MUST evaluate error and result assertions when executing these operations in the callback. +Test runners MUST allow any errors from the callback operation(s) to propagate to `withTransaction`, irrespective of +[ignoreResultAndError](#operation_ignoreResultAndError) or [expectError](#operation_expectError). For example, if a +callback operation raises an error, it should be possible to assert that error at both the callback operation and +`withTransaction` level. + ### Bucket Operations These operations and their arguments may be documented in the following specifications: @@ -3311,6 +3316,8 @@ other specs *and* collating spec changes developed in parallel or during the sam ## Changelog +- 2024-02-14: Clarify that errors raised from callback operations should always propagate to `withTransaction`. + - 2024-02-12: Clarify that `targetedFailPoint` should only be used when `useMultipleMongoses` is true and not on load-balanced topologies.