summaryrefslogtreecommitdiff
path: root/python/problems/introduction/fahrenheit_to_celsius
diff options
context:
space:
mode:
Diffstat (limited to 'python/problems/introduction/fahrenheit_to_celsius')
-rw-r--r--python/problems/introduction/fahrenheit_to_celsius/common.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/problems/introduction/fahrenheit_to_celsius/common.py b/python/problems/introduction/fahrenheit_to_celsius/common.py
index 5c8e0cd..34f2832 100644
--- a/python/problems/introduction/fahrenheit_to_celsius/common.py
+++ b/python/problems/introduction/fahrenheit_to_celsius/common.py
@@ -19,7 +19,7 @@ hint_type = {
'no_input_call': Hint('no_input_call'),
}
-def test(session, code):
+def test(python, code):
# List of inputs: (expression to eval, stdin).
test_in = [
(None, '0\n'),
@@ -31,7 +31,7 @@ def test(session, code):
]
# List of outputs: (expression result, stdout, stderr, exception).
- answers = session.get_python().run(code=code, inputs=test_in, timeout=1.0)
+ answers = python(code=code, inputs=test_in, timeout=1.0)
outputs = [ans[1] for ans in answers]
n_correct = 0
@@ -40,7 +40,7 @@ def test(session, code):
n_correct += 1
return n_correct, len(test_in)
-def hint(session, code):
+def hint(python, code):
if not code:
return [{'id': 'plan'}]
if not has_token_sequence(code, ['input']):