コード例 #1
0
 def test_smoketest_init(self):
     """__init__ - class constructor is called with no arguments."""
     c = threadedcomponent()
     
     self.assert_(len(c.inboxes.keys()) == 2, "by default, has 2 inboxes")
     self.assert_("inbox" in c.inboxes.keys(), "by default, has 'inbox' inbox")
     self.assert_("control" in c.inboxes.keys(), "by default, has 'control' inbox")
     
     self.assert_(len(c.outboxes.keys()) == 2, "by default, has 2 outboxes")
     self.assert_("outbox" in c.outboxes.keys(), "by default, has 'outbox' outbox")
     self.assert_("signal" in c.outboxes.keys(), "by default, has 'signal' outbox")
コード例 #2
0
    def test_smoketest_init(self):
        """__init__ - class constructor is called with no arguments."""
        c = threadedcomponent()

        self.assert_(len(c.inboxes.keys()) == 2, "by default, has 2 inboxes")
        self.assert_("inbox" in c.inboxes.keys(),
                     "by default, has 'inbox' inbox")
        self.assert_("control" in c.inboxes.keys(),
                     "by default, has 'control' inbox")

        self.assert_(len(c.outboxes.keys()) == 2, "by default, has 2 outboxes")
        self.assert_("outbox" in c.outboxes.keys(),
                     "by default, has 'outbox' outbox")
        self.assert_("signal" in c.outboxes.keys(),
                     "by default, has 'signal' outbox")
コード例 #3
0
 def test_smoketest_oneargs(self):
     """__init__ - accepts one argument"""
     self.assert_(threadedcomponent(10))
コード例 #4
0
 def test_smoketest_args(self):
     """__init__ - can accept no arguments"""
     self.assert_(threadedcomponent())
コード例 #5
0
 def test_smoketest_oneargs(self):
     """__init__ - accepts one argument"""
     self.assert_(threadedcomponent(10))
コード例 #6
0
 def test_smoketest_args(self):
     """__init__ - can accept no arguments"""
     self.assert_(threadedcomponent())