--- a/cubicweb/hooks/notification.py Thu Apr 18 15:09:36 2019 +0200
+++ b/cubicweb/hooks/notification.py Tue Apr 23 09:33:52 2019 +0200
@@ -70,6 +70,12 @@
# to prevent them all.
self.exception('Notification failed')
+ if self.cnx.vreg.config.mode == "test":
+ # reraise in testing context because we actually want to
+ # have those exceptions here and that self.exception is
+ # filtered in test context
+ raise
+
class NotificationHook(hook.Hook):
__abstract__ = True
--- a/doc/changes/3.27.rst Thu Apr 18 15:09:36 2019 +0200
+++ b/doc/changes/3.27.rst Tue Apr 23 09:33:52 2019 +0200
@@ -27,6 +27,10 @@
* Python 2 support has been dropped.
+* Exceptions in notification hooks aren't catched-all anymore during tests so
+ one can expect tests that seem to pass (but were actually silently failing)
+ to fail now.
+
Deprecated code drops
---------------------