def METHOD_NAME(self):
    """
    Test that outer_atomic raises an error if it is nested inside
    another atomic.
    """
    outer_atomic()(do_nothing)()  # pylint: disable=not-callable
    with atomic():
        atomic()(do_nothing)()  # pylint: disable=not-callable
    with outer_atomic():
        atomic()(do_nothing)()  # pylint: disable=not-callable
    with self.assertRaisesRegex(TransactionManagementError, 'Cannot be inside an atomic block.'):
        with atomic():
            outer_atomic()(do_nothing)()  # pylint: disable=not-callable
    with self.assertRaisesRegex(TransactionManagementError, 'Cannot be inside an atomic block.'):
        with outer_atomic():
            outer_atomic()(do_nothing)()  # pylint: disable=not-callable