Browse Source

tests passing

Ask Solem 12 years ago
parent
commit
f14dd55c8c

+ 0 - 1
celery/datastructures.py

@@ -472,7 +472,6 @@ class LimitedSet(object):
             self._data.pop(item[1])
             i += 1
 
-
     def update(self, other, heappush=heappush):
         if isinstance(other, self.__class__):
             self._data.update(other._data)

+ 2 - 1
celery/tests/bin/test_celeryd.py

@@ -638,7 +638,8 @@ class test_signal_handlers(WorkerAppCase):
     @disable_stdouts
     @patch('atexit.register')
     @patch('os.fork')
-    def test_worker_restart_handler(self, fork, register):
+    @patch('os.close')
+    def test_worker_restart_handler(self, _close, fork, register):
         fork.return_value = 0
         if getattr(os, 'execv', None) is None:
             raise SkipTest('platform does not have excv')

+ 3 - 1
celery/tests/worker/test_autoreload.py

@@ -223,7 +223,9 @@ class test_Autoreloader(AppCase):
         x.body()
 
     @patch('celery.worker.autoreload.file_hash')
-    def test_maybe_modified(self, fhash):
+    @patch('os.path.exists')
+    def test_maybe_modified(self, exists, fhash):
+        exists.return_value = True
         fhash.return_value = 'abcd'
         x = Autoreloader(Mock(), modules=[__name__])
         x._hashes = {}