somewhat better failure messages

This commit is contained in:
Jean-Paul Calderone 2019-03-04 18:52:25 -05:00
parent 944cb6f425
commit 8bec797f66

View File

@ -183,7 +183,10 @@ class INotifyTests(AsyncTestCase):
# delay our check of that watch state a bit.
def _():
try:
self.assertFalse(self.inotify._isWatched(subdir))
self.assertFalse(
self.inotify._isWatched(subdir),
"{} not un-watched. watches = {}".format(subdir, self.inotify._watches),
)
d.callback(None)
except Exception:
d.errback()
@ -196,7 +199,10 @@ class INotifyTests(AsyncTestCase):
callbacks=[_callback],
recursive=True,
)
self.assertTrue(self.inotify._isWatched(subdir))
self.assertTrue(
self.inotify._isWatched(subdir),
"{} not watched. watches = {}".format(subdir, self.inotify._watches),
)
subdir.remove()
return d