Ejemplo n.º 1
0
 def setUp(self):
     self.foo = base.State('foo', 'Foo')
     self.bar = base.State('bar', 'Bar')
     self.baz = base.State('baz', 'Baz')
     self.baz2 = base.State('baz', 'Baz')
     self.foobar = base.Transition('foobar', self.foo, self.bar)
     self.foobar2 = base.Transition('foobar', self.foo, self.bar)
     self.gobaz = base.Transition('gobaz', [self.foo, self.bar], self.baz)
     self.tl = base.TransitionList([self.foobar, self.gobaz])
Ejemplo n.º 2
0
 def test_repr(self):
     wrapper = base.ImplementationWrapper(self.dummy, 'state1',
         base.Transition('foobar', [base.State('foo', 'Foo')],
             base.State('bar', 'Bar')), None,
         base.noop)
     self.assertIn('foobar', repr(wrapper))
     self.assertIn('state1', repr(wrapper))
     self.assertIn(repr(base.noop), repr(wrapper))
Ejemplo n.º 3
0
 def setUp(self):
     self.foo = base.State('foo', 'Foo')
     self.bar = base.State('bar', 'Bar')
     self.baz = base.State('baz', 'Baz')
     self.foobar = base.Transition('foobar', self.foo, self.bar)