Changes between Initial Version and Version 1 of Ticket #30457, comment 18


Ignore:
Timestamp:
May 20, 2020, 5:32:42 AM (4 years ago)
Author:
Mariusz Felisiak

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #30457, comment 18

    initial v1  
    1 I've created an alternate PR that adds `TestCase.captureOnCommitCallbacks` : [PR #12944](https://github.com/django/django/pull/12944). This returns a context manager that captures the hooks and optionally calls them as the context manager yields. It also returns them as a list so assertions can be made on the hooks, and they can be selectively executed.
     1I've created an alternate PR that adds `TestCase.captureOnCommitCallbacks` : [https://github.com/django/django/pull/12944 PR #12944]. This returns a context manager that captures the hooks and optionally calls them as the context manager yields. It also returns them as a list so assertions can be made on the hooks, and they can be selectively executed.
    22
    33I also put the code in a package tested on Django 2.0+: https://github.com/adamchainz/django-capture-on-commit-callbacks
Back to Top