Skip to content

Commit

Permalink
fix pyramide -> wronginput
Browse files Browse the repository at this point in the history
  • Loading branch information
Jelleas committed Dec 31, 2017
1 parent d088b3e commit 7bff822
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions tests/progbeta2017/module1/piramideTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,12 @@ def exactMario23(test):

@t.test(10)
def handlesWrongInput(test):
test.test = lambda : not assertlib.contains(lib.outputOf(_fileName, stdinArgs=[-100]), "#")
test.test = lambda : not assertlib.contains(lib.outputOf(_fileName, stdinArgs=[100]), "#")
test.test = lambda : not assertlib.contains(lib.outputOf(_fileName, stdinArgs=[24]), "#")
def testMethod():
for wrongInput in [-100, 100, 24]:
output = lib.outputOf(_fileName, stdinArgs=[wrongInput])
if assertlib.contains(output, "#"):
return False
return True

test.test = testMethod
test.description = lambda : "handelt een verkeerde input van -100, 100 en 24 af"

0 comments on commit 7bff822

Please sign in to comment.