def test_same_state_from_state(self): """ Test if state is the same than the input state. """ result = new_state( vertice=self.vertice, event={}, state=Check.OK ) self.assertFalse(result)
def test_same_state_from_event(self): """ Test if state is the same than the one from an event. """ result = new_state( vertice=self.vertice, event={'state': Check.OK} ) self.assertFalse(result)
def test_new_state_from_event(self): """ Test if state is different from an event. """ result = new_state( vertice=self.vertice, event={'state': Check.MINOR} ) self.assertTrue(result)
def test_new_state_from_state(self): """ Test if state is different than the input state. """ result = new_state( vertice=self.vertice, event={}, state=Check.MINOR ) self.assertTrue(result)