def test_set_transition_type_str(self): """ Test the transition_type setter with a str """ # GIVEN: A AlignmentTransitionsPage instance page = AlignmentTransitionsPage() # WHEN: The property is set page.transition_type = TransitionType.to_string(TransitionType.Convex) # THEN: The combobox should be correct assert page.transition_effect_combo_box.currentIndex() == 2
def test_set_transition_type_exception(self): """ Test the transition_type setter with something other than a str or int """ # GIVEN: A AlignmentTransitionsPage instance page = AlignmentTransitionsPage() # WHEN: The property is set # THEN: An exception is raised with pytest.raises( TypeError, match='transition_type must either be a string or an int'): page.transition_type = []