diff --git a/src/wormhole/test/test_wormhole.py b/src/wormhole/test/test_wormhole.py index 824f23f..0dc8eef 100644 --- a/src/wormhole/test/test_wormhole.py +++ b/src/wormhole/test/test_wormhole.py @@ -127,7 +127,8 @@ class Wormholes(ServerBase, unittest.TestCase): version1 = yield w1.when_version() version2 = yield w2.when_version() - # TODO: add the ability to set app-versions + # app-versions are exercised properly in test_versions, this just + # tests the defaults self.assertEqual(version1, {}) self.assertEqual(version2, {}) diff --git a/src/wormhole/wormhole.py b/src/wormhole/wormhole.py index 0077020..a7a8606 100644 --- a/src/wormhole/wormhole.py +++ b/src/wormhole/wormhole.py @@ -131,7 +131,10 @@ class _DeferredWormhole(object): # from above def when_code(self): # TODO: consider throwing error unless one of allocate/set/input_code - # was called first + # was called first. It's legit to grab the Deferred before triggering + # the process that will cause it to fire, but forbidding that + # ordering would make it easier to cause programming errors that + # forget to trigger it entirely. if self._observer_result is not None: return defer.fail(self._observer_result) if self._code is not None: