- F6EB911B7A54EC1EF368E1EED8202AA2E385086F3D5509C08EB8BB78D216FF2408B7409B5F4F368D46EA98475C4AFB3A67A094EDE9109278AD0CB7EA93459F4B
+ 90668D46C39A64258B943CF8FF176E84B0B98EB662B8E6193B717F6582BFEAE981698754FF6F4AA7EFDA8F672DED907EE0680A5F3C175E3848718C712A200F2D
blatta/tests/test_station.py
(1 . 4)(1 . 5)
381 # https://stackoverflow.com/questions/1896918/running-unittest-with-typical-test-directory-structure
382 import time
383 import unittest
384 import logging
385 from mock import Mock
(75 . 6)(76 . 16)
387 def tearDown(self):
388 pass
389
390 def test_clean_getdata_requests_clears_expired_hashes(self):
391 self.station.getdata_requests["abc"] = time.time() - 15
392 self.station.clean_getdata_requests()
393 self.assertEqual(len(self.station.getdata_requests), 0)
394
395 def test_clean_getdata_requests_retains_valid_hashes(self):
396 self.station.getdata_requests["abc"] = time.time()
397 self.station.clean_getdata_requests()
398 self.assertEqual(len(self.station.getdata_requests), 1)
399
400 def test_embargo_bounce_ordering(self):
401 self.skipTest("the tested code has been re-implemented")
402 peer1 = Mock()