[Scipy-svn] r5324 - trunk/scipy/weave/tests

scipy-svn@scip... scipy-svn@scip...
Sun Jan 4 08:21:05 CST 2009


Author: stefan
Date: 2009-01-04 08:20:49 -0600 (Sun, 04 Jan 2009)
New Revision: 5324

Modified:
   trunk/scipy/weave/tests/test_ast_tools.py
   trunk/scipy/weave/tests/test_blitz_tools.py
   trunk/scipy/weave/tests/test_ext_tools.py
   trunk/scipy/weave/tests/test_slice_handler.py
Log:
Use assert_equal instead of the more verbose print_assert_equal.

Modified: trunk/scipy/weave/tests/test_ast_tools.py
===================================================================
--- trunk/scipy/weave/tests/test_ast_tools.py	2009-01-04 13:26:17 UTC (rev 5323)
+++ trunk/scipy/weave/tests/test_ast_tools.py	2009-01-04 14:20:49 UTC (rev 5324)
@@ -11,7 +11,7 @@
         import parser
         ast_list = parser.suite(expr).tolist()
         actual = ast_tools.harvest_variables(ast_list)
-        print_assert_equal(expr,actual,desired)
+        assert_equal(expr,actual,desired)
 
     def test_simple_expr(self):
         """convert simple expr to blitz

Modified: trunk/scipy/weave/tests/test_blitz_tools.py
===================================================================
--- trunk/scipy/weave/tests/test_blitz_tools.py	2009-01-04 13:26:17 UTC (rev 5323)
+++ trunk/scipy/weave/tests/test_blitz_tools.py	2009-01-04 14:20:49 UTC (rev 5324)
@@ -20,7 +20,7 @@
         actual = blitz_tools.ast_to_blitz_expr(ast_list)
         actual = remove_whitespace(actual)
         desired = remove_whitespace(desired)
-        print_assert_equal(expr,actual,desired)
+        assert_equal(expr,actual,desired)
 
     def test_simple_expr(self):
         """convert simple expr to blitz

Modified: trunk/scipy/weave/tests/test_ext_tools.py
===================================================================
--- trunk/scipy/weave/tests/test_ext_tools.py	2009-01-04 13:26:17 UTC (rev 5323)
+++ trunk/scipy/weave/tests/test_ext_tools.py	2009-01-04 14:20:49 UTC (rev 5324)
@@ -133,7 +133,7 @@
         cd.name, cd.var_type = 'c', types.IntType
         desired = [ad,bd,cd]
         expr = ""
-        print_assert_equal(expr,actual,desired)
+        assert_equal(expr,actual,desired)
 
 if __name__ == "__main__":
     nose.run(argv=['', __file__])

Modified: trunk/scipy/weave/tests/test_slice_handler.py
===================================================================
--- trunk/scipy/weave/tests/test_slice_handler.py	2009-01-04 13:26:17 UTC (rev 5323)
+++ trunk/scipy/weave/tests/test_slice_handler.py	2009-01-04 14:20:49 UTC (rev 5324)
@@ -9,7 +9,7 @@
         pos = slice_vars['pos']
         ast_list = slice_handler.build_slice_atom(slice_vars,pos)
         actual = ast_to_string(ast_list)
-        print_assert_equal('',actual,desired)
+        assert_equal('',actual,desired)
     def test_exclusive_end(self):
         slice_vars = {'begin':'1', 'end':'2', 'step':'_stp',
                       'single_index':'_index','pos':0}
@@ -24,7 +24,7 @@
         found, data = find_first_pattern(ast_tuple,indexed_array_pattern)
         subscript = data['subscript_list'][1] #[0] is symbol, [1] is the supscript
         actual = slice_handler.slice_ast_to_dict(subscript)
-        print_assert_equal(suite_string,actual,desired)
+        assert_equal(suite_string,actual,desired)
 
     def test_empty_2_slice(self):
         """match slice from a[:]"""
@@ -126,7 +126,7 @@
         # but differently formatted string will compare equally
         actual = replace_whitespace(actual)
         desired = replace_whitespace(desired)
-        print_assert_equal(suite_string,actual,desired)
+        assert_equal(suite_string,actual,desired)
 
     def test_simple_expr(self):
         """transform a[:] to slice notation"""



More information about the Scipy-svn mailing list