diff options
author | Martin <martin@leo.fri1.uni-lj.si> | 2015-10-09 16:35:23 +0200 |
---|---|---|
committer | Martin <martin@leo.fri1.uni-lj.si> | 2015-10-09 16:35:23 +0200 |
commit | 95e107bf9e6a288969e4a83aee1a7062990f3b67 (patch) | |
tree | f69b15164a30d464f6f7b340634095716344b1ec /python/problems/functions/greatest_absolutist | |
parent | fd31d7d74e58796f3a5a7c84b4b19cb4af59ef4c (diff) |
Fixed testing for most problems.
Diffstat (limited to 'python/problems/functions/greatest_absolutist')
-rw-r--r-- | python/problems/functions/greatest_absolutist/common.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/python/problems/functions/greatest_absolutist/common.py b/python/problems/functions/greatest_absolutist/common.py index 2d80097..564d0c8 100644 --- a/python/problems/functions/greatest_absolutist/common.py +++ b/python/problems/functions/greatest_absolutist/common.py @@ -35,6 +35,10 @@ hint_type = { def test(python, code): + tokens = get_tokens(code) + if not has_token_sequence(tokens, ['def', 'max_abs']): + return False, [{'id' : 'no_func_name', 'args' : {'func_name' : 'max_abs'}}] + test_lists = [[6, 4, 2, 0], [4, 6, 2, 0], [4, 2, 6, 0], |