Ask Solem пре 16 година
родитељ
комит
c579d1332f
4 измењених фајлова са 12 додато и 12 уклоњено
  1. 3 2
      celery/tests/test_supervisor.py
  2. 1 2
      celery/tests/test_worker_job.py
  3. 7 7
      celery/tests/utils.py
  4. 1 1
      contrib/doc4allmods

+ 3 - 2
celery/tests/test_supervisor.py

@@ -41,6 +41,7 @@ class MockProcess(object):
     def join(self, timeout=None):
         self._joined = True
 
+
 class TestDiv(unittest.TestCase):
 
     def test_raise_ping_timeout(self):
@@ -52,7 +53,7 @@ class TestOFASupervisor(unittest.TestCase):
     def test_init(self):
         s = OFASupervisor(target=target_one, args=[2, 4, 8], kwargs={})
         s.Process = MockProcess
-    
+
     def test__is_alive(self):
         s = OFASupervisor(target=target_one, args=[2, 4, 8], kwargs={})
         s.Process = MockProcess
@@ -69,7 +70,7 @@ class TestOFASupervisor(unittest.TestCase):
         s.Process = MockProcess
         self.assertRaises(MaxRestartsExceededError, s.start)
         MockProcess.alive = True
-    
+
     def test_start_is_alive_timeout(self):
         MockProcess.alive = True
         MockProcess.timeout_on_is_alive = True

+ 1 - 2
celery/tests/test_worker_job.py

@@ -53,7 +53,7 @@ class TestJail(unittest.TestCase):
         from django.db import connection
         connection._was_closed = False
         old_connection_close = connection.close
-        
+
         def monkeypatched_connection_close(*args, **kwargs):
             connection._was_closed = True
             return old_connection_close(*args, **kwargs)
@@ -232,4 +232,3 @@ class TestTaskWrapper(unittest.TestCase):
         self.assertTrue("ERROR" in logvalue)
 
         conf.SEND_CELERY_TASK_ERROR_EMAILS = False
-         

+ 7 - 7
celery/tests/utils.py

@@ -4,29 +4,29 @@ from StringIO import StringIO
 import os
 import sys
 import __builtin__
- 
+
 
 @contextmanager
 def mask_modules(*modnames):
     """Ban some modules from being importable inside the context
- 
+
     For example:
- 
+
         >>> with missing_modules("sys"):
         ...     try:
         ...         import sys
         ...     except ImportError:
         ...         print "sys not found"
         sys not found
- 
+
         >>> import sys
         >>> sys.version
         (2, 5, 2, 'final', 0)
- 
+
     """
- 
+
     realimport = __builtin__.__import__
-    
+
     def myimp(name, *args, **kwargs):
         if name in modnames:
             raise ImportError("No module named %s" % name)

+ 1 - 1
contrib/doc4allmods

@@ -2,7 +2,7 @@
 
 PACKAGE="$1"
 SKIP_PACKAGES="$PACKAGE tests management urls"
-SKIP_FILES="celery.bin.rst"
+SKIP_FILES="celery.bin.rst celery.serialization.rst"
 
 modules=$(find "$PACKAGE" -name "*.py")