summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimotej Lazar <timotej.lazar@araneo.org>2015-07-07 11:02:05 +0200
committerAleš Smodiš <aless@guru.si>2015-08-11 14:26:03 +0200
commit8c1ad089121249c1f81838ce6871f3beb86787da (patch)
tree378e922a246c641b9df2ef2fa4a1bc2b104a12de
parent90dadf3c0c750444bc8fe652bc54fda20c43c94b (diff)
Fix monkey.test.print_hint
-rwxr-xr-xmonkey/test.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/monkey/test.py b/monkey/test.py
index 6887a2c..6549c1b 100755
--- a/monkey/test.py
+++ b/monkey/test.py
@@ -58,8 +58,8 @@ def print_hint(code, solution, steps, fix_time, n_tested):
for step_type, pos, a, b in steps:
print(' {}: {} {} → {}'.format(pos, step_type, stringify(a), stringify(b)))
print(colored(' Hints', 'blue'))
- for loc, msg in fix_hints(code, steps):
- print(' {}-{}: {}'.format(loc['start'], loc['end'], msg))
+ for fix_type, start, end, msg in fix_hints(code, steps):
+ print(' {}-{}: {} (fix type: {})'.format(start, end, msg, fix_type))
print(colored(' Final version', 'blue'))
print(indent(compose(annotate(solution)), 2))
else: