예제 #1
0
 def test_full_definition(self):
     decl = base.on_enter_state('foo', 'bar', priority=3, field='st')
     self.assertEqual(3, decl.priority)
     self.assertEqual('st', decl.field)
     self.assertEqual(('foo', 'bar'), decl.names)
예제 #2
0
 def test_definition_no_transition_name(self):
     decl = base.on_enter_state()
     self.assertEqual(0, decl.priority)
     self.assertEqual('', decl.field)
     self.assertEqual(('*',), decl.names)
예제 #3
0
 def test_simple_definition(self):
     decl = base.on_enter_state('foo', 'bar')
     self.assertEqual(0, decl.priority)
     self.assertEqual('', decl.field)
     self.assertEqual(('foo', 'bar'), decl.names)
예제 #4
0
 def test_full_definition(self):
     decl = base.on_enter_state('foo', 'bar', priority=3, field='st')
     self.assertEqual(3, decl.priority)
     self.assertEqual('st', decl.field)
     self.assertEqual(('foo', 'bar'), decl.names)
예제 #5
0
 def test_definition_no_transition_name(self):
     decl = base.on_enter_state()
     self.assertEqual(0, decl.priority)
     self.assertEqual('', decl.field)
     self.assertEqual(('*',), decl.names)
예제 #6
0
 def test_simple_definition(self):
     decl = base.on_enter_state('foo', 'bar')
     self.assertEqual(0, decl.priority)
     self.assertEqual('', decl.field)
     self.assertEqual(('foo', 'bar'), decl.names)