@@ -126,28 +126,29 @@ def test_run_solution_dir():
126126
127127 file_dir = "a/b"
128128 file_path = "a/b/c"
129- solution_location = "solution "
129+ workspace_location = "workspace "
130130
131131 with in_temp_dir ():
132- write_file (file_dir , "c" , code )
132+ write_file ("solution/" + file_dir , "c" , code )
133133
134- os .makedirs (solution_location )
135- with ChDir (solution_location ):
134+ os .makedirs (workspace_location )
135+ with ChDir (workspace_location ):
136136 write_file (file_dir , "c" , code )
137137
138- chain = setup_state ("" , "" , pec = "" )
138+ chain = setup_state ("" , "" , pec = "" )
139139
140- child = chain .check_file (file_path , solution_code = code )
140+ child = chain .check_file (file_path , solution_code = code )
141141
142- child .run (file_dir ).check_object ("c" )
143- child .run ().check_object ("c" )
142+ child .run (file_dir ).check_object ("c" )
143+ child .run ().check_object ("c" )
144144
145145
146146def test_run_with_absolute_dir ():
147147 code = 'from pathlib import Path; c = Path("c").read_text(encoding="utf-8")'
148148
149149 file_dir = "a/b"
150150 solution_location = "solution"
151+ workspace_location = "workspace"
151152
152153 with in_temp_dir ():
153154 os .makedirs (file_dir )
@@ -159,12 +160,14 @@ def test_run_with_absolute_dir():
159160
160161 write_file (solution_location , "c" , code )
161162
162- chain = setup_state ("" , "" , pec = "" )
163+ os .makedirs (workspace_location )
164+ with ChDir (workspace_location ):
165+ chain = setup_state ("" , "" , pec = "" )
163166
164- child = chain .check_file (abs_file_path , solution_code = code )
167+ child = chain .check_file (abs_file_path , solution_code = code )
165168
166- child .run (abs_dir ).check_object ("c" )
167- child .run ().check_object ("c" )
169+ child .run (abs_dir ).check_object ("c" )
170+ child .run ().check_object ("c" )
168171
169172
170173def test_run_custom_solution_dir ():
0 commit comments