Browse Source

add unit test for sleep function

pull/41/head
Miguel Grinberg 9 years ago
parent
commit
a3ae2a9384
  1. 5
      tests/test_server.py

5
tests/test_server.py

@ -423,3 +423,8 @@ class TestServer(unittest.TestCase):
s.start_background_task('foo', 'bar', baz='baz') s.start_background_task('foo', 'bar', baz='baz')
s.eio.start_background_task.assert_called_once_with('foo', 'bar', s.eio.start_background_task.assert_called_once_with('foo', 'bar',
baz='baz') baz='baz')
def test_sleep(self, eio):
s = server.Server()
s.sleep(1.23)
s.eio.sleep.assert_called_once_with(1.23)

Loading…
Cancel
Save