예제 #1
0
 def generic_check(self,suite_string,desired):
     ast_list = parser.suite(suite_string).tolist()
     slice_handler.transform_slices(ast_list)
     actual = ast_to_string(ast_list)
     # Remove white space from expressions so that equivalent
     # but differently formatted string will compare equally
     actual = remove_whitespace(actual)
     desired = remove_whitespace(desired)
     assert_equal(actual,desired,suite_string)
예제 #2
0
 def generic_check(self, suite_string, desired):
     ast_list = parser.suite(suite_string).tolist()
     slice_handler.transform_slices(ast_list)
     actual = ast_to_string(ast_list)
     # Remove white space from expressions so that equivalent
     # but differently formatted string will compare equally
     actual = remove_whitespace(actual)
     desired = remove_whitespace(desired)
     assert_equal(actual, desired, suite_string)
예제 #3
0
 def generic_check(self,slice_vars,desired):
     pos = slice_vars['pos']
     ast_list = slice_handler.build_slice_atom(slice_vars,pos)
     actual = ast_to_string(ast_list)
     assert_equal(actual,desired)
예제 #4
0
 def generic_check(self, slice_vars, desired):
     pos = slice_vars['pos']
     ast_list = slice_handler.build_slice_atom(slice_vars, pos)
     actual = ast_to_string(ast_list)
     assert_equal(actual, desired)