def test_wrap_exception_with_notifier(self):
        notifier = FakeNotifier()
        wrapped = exception.wrap_exception(notifier, "publisher", "event",
                                           "level")
        self.assertRaises(exception.Error, wrapped(bad_function_exception))
        self.assertEquals(notifier.provided_publisher, "publisher")
        self.assertEquals(notifier.provided_event, "event")
        self.assertEquals(notifier.provided_priority, "level")
        for key in ['exception', 'args']:
            self.assertTrue(key in notifier.provided_payload.keys())
dataset/ETHPy150Open nii-cloud/dodai-compute/nova/tests/test_exception.py/WrapExceptionTestCase.test_wrap_exception_with_notifier/original