Explorar o código

Make testing the message less brittle.

Mike Naberezny %!s(int64=16) %!d(string=hai) anos
pai
achega
ad355a79d5
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/supervisor/tests/test_supervisorctl.py

+ 2 - 2
src/supervisor/tests/test_supervisorctl.py

@@ -762,8 +762,8 @@ class TestDefaultControllerPlugin(unittest.TestCase):
                          'http://localhost:92491/mainlogtail')
         self.assertEqual(error[0],
                          'http://localhost:92491/mainlogtail')
-        self.assertEqual(error[1],
-                  "Cannot connect, error: socket.error ((32, 'Broken pipe'))")
+        for msg in ('Cannot connect', 'socket.error', '32', 'Broken pipe'):
+            self.assertTrue(msg in error[1])
 
     def test_maintail_nobytes(self):
         plugin = self._makeOne()