Skip to content

Raise error in tests if entering transaction and the testcase-transaction already has on-commit callbacks #31

@meshy

Description

@meshy

A test might naively set up on-commit callbacks in a test's transaction (and not execute them) before we enter a transaction block later in the test.

As it stands, that would then cause the callbacks to be executed after the transaction exits. We should default to raising an error when entering the transaction instead (and offer a setting to opt out of this behaviour).

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions