<s> from base_test_case import BaseTestCase <EOL> from cursesmenu import CursesMenu <EOL> from cursesmenu . items import SelectionItem <EOL> class TestSelectionItem ( BaseTestCase ) : <EOL> def setUp ( self ) : <EOL> super ( TestSelectionItem , self ) . setUp ( ) <EOL> self . menu = CursesMenu ( "<STR_LIT>" , "<STR_LIT>" ) <EOL> def test_init ( self ) : <EOL> selection_item_1 = SelectionItem ( "<STR_LIT>" , <NUM_LIT:1> , self . menu ) <EOL> selection_item_2 = SelectionItem ( text = "<STR_LIT>" , index = <NUM_LIT:2> , menu = self . menu ) <EOL> self . assertEqual ( selection_item_1 . text , "<STR_LIT>" ) <EOL> self . assertEqual ( selection_item_2 . text , "<STR_LIT>" ) <EOL> self . assertEqual ( selection_item_1 . menu , self . menu ) <EOL> self . assertEqual ( selection_item_2 . menu , self . menu ) <EOL> self . assertTrue ( selection_item_1 . should_exit ) <EOL> self . assertTrue ( selection_item_2 . should_exit ) </s>
