MCPcopy Index your code
hub / github.com/datacamp/pythonwhat / test_running_code_isolation_run

Function test_running_code_isolation_run

tests/test_local.py:37–45  ·  view source on GitHub ↗
(sol_code, stu_code)

Source from the content-addressed store, hash-verified

35
36@pytest.mark.parametrize("sol_code, stu_code", [modify_sys])
37def test_running_code_isolation_run(sol_code, stu_code):
38 # test that setup_state is isolated
39 chain = setup_state(sol_code, stu_code, pec="")
40 chain._state.solution_code = sol_code
41 chain._state.student_code = stu_code
42
43 with verify_sct(False):
44 # test that run is isolated
45 chain.run().has_equal_value(name="bar", override="bar")
46
47
48@pytest.mark.parametrize(

Callers

nothing calls this directly

Calls 3

setup_stateFunction · 0.90
verify_sctFunction · 0.90
runMethod · 0.80

Tested by

no test coverage detected