From 5796496baf66cecf8350ad1c48e01f8a6b0c90dd Mon Sep 17 00:00:00 2001 From: David Halter Date: Mon, 7 Jan 2013 00:36:37 +0100 Subject: [PATCH] corrected problem with line numbers --- test/refactor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/refactor.py b/test/refactor.py index 8e01152d..d09c3d35 100755 --- a/test/refactor.py +++ b/test/refactor.py @@ -51,7 +51,7 @@ def run_test(source, f_name, lines_to_execute): path = refactoring_test_dir + os.path.sep + f_name try: - script = api.Script(source, line_nr + 1, index, path) + script = api.Script(source, line_nr, index, path) refactor_func = getattr(refactoring, f_name.replace('.py', '')) args = (script, new_name) if new_name else (script,) refactor_object = refactor_func(*args) @@ -73,7 +73,7 @@ def run_test(source, f_name, lines_to_execute): if second != result: print('test @%s: not the same result, %s' % (line_nr - 1, name)) - print(' ' + repr(result)) + print(' ' + repr(str(result))) print(' ' + repr(second)) fails += 1 except Exception: