<s> from nose . tools import assert_equal <EOL> from nose . tools import raises <EOL> class TestStacks ( object ) : <EOL> @ raises ( Exception ) <EOL> def test_pop_on_empty ( self , num_stacks , stack_size ) : <EOL> print ( '<STR_LIT>' ) <EOL> stacks = Stacks ( num_stacks , stack_size ) <EOL> stacks . pop ( <NUM_LIT:0> ) <EOL> @ raises ( Exception ) <EOL> def test_push_on_full ( self , num_stacks , stack_size ) : <EOL> print ( '<STR_LIT>' ) <EOL> stacks = Stacks ( num_stacks , stack_size ) <EOL> for i in range ( <NUM_LIT:0> , stack_size ) : <EOL> stacks . push ( <NUM_LIT:2> , i ) <EOL> stacks . push ( <NUM_LIT:2> , stack_size ) <EOL> def test_stacks ( self , num_stacks , stack_size ) : <EOL> print ( '<STR_LIT>' ) <EOL> stacks = Stacks ( num_stacks , stack_size ) <EOL> stacks . push ( <NUM_LIT:0> , <NUM_LIT:1> ) <EOL> stacks . push ( <NUM_LIT:0> , <NUM_LIT:2> ) <EOL> stacks . push ( <NUM_LIT:1> , <NUM_LIT:3> ) <EOL> stacks . push ( <NUM_LIT:2> , <NUM_LIT:4> ) <EOL> print ( '<STR_LIT>' ) <EOL> assert_equal ( stacks . pop ( <NUM_LIT:0> ) , <NUM_LIT:2> ) <EOL> assert_equal ( stacks . pop ( <NUM_LIT:0> ) , <NUM_LIT:1> ) <EOL> assert_equal ( stacks . pop ( <NUM_LIT:1> ) , <NUM_LIT:3> ) <EOL> assert_equal ( stacks . pop ( <NUM_LIT:2> ) , <NUM_LIT:4> ) <EOL> print ( '<STR_LIT>' ) <EOL> def main ( ) : <EOL> num_stacks = <NUM_LIT:3> <EOL> stack_size = <NUM_LIT:100> <EOL> test = TestStacks ( ) <EOL> test . test_pop_on_empty ( num_stacks , stack_size ) <EOL> test . test_push_on_full ( num_stacks , stack_size ) <EOL> test . test_stacks ( num_stacks , stack_size ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> main ( ) </s>
