mitogen/tests/local_test.py

24 lines
439 B
Python
Raw Normal View History

2017-09-29 10:34:09 +00:00
import os
import unittest
import mitogen
import mitogen.ssh
import mitogen.utils
import testlib
import plain_old_module
class LocalTest(testlib.RouterMixin, unittest.TestCase):
stream_class = mitogen.ssh.Stream
def test_stream_name(self):
context = self.router.local()
pid = context.call(os.getpid)
self.assertEquals('local.%d' % (pid,), context.name)
if __name__ == '__main__':
unittest.main()