You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
740 B
25 lines
740 B
import unittest
|
|
import mock
|
|
|
|
from os.path import dirname, realpath
|
|
from sys import argv, path
|
|
path.append(dirname(dirname(realpath(__file__))) + '/lib')
|
|
|
|
from Communication.DatagramEntryPoint import DatagramEntryPoint
|
|
|
|
class TestDatagramEntryPoint(unittest.TestCase):
|
|
def setUp(self):
|
|
self._transport = mock.Mock()
|
|
self._protocol = mock.Mock()
|
|
self._entrypoint = DatagramEntryPoint(self._transport, self._protocol)
|
|
|
|
def testAny(self):
|
|
self._transport.bind.assert_called_once_with()
|
|
|
|
def suite():
|
|
return unittest.TestLoader().loadTestsFromTestCase(TestDatagramEntryPoint)
|
|
|
|
if __name__ == '__main__':
|
|
unittest.TextTestRunner(verbosity=2).run(suite())
|
|
|
|
# vim: set ft=python et ts=8 sw=4 sts=4:
|