shell
This commit is contained in:
parent
b8ac741f24
commit
9e0b9b67e7
@ -40,7 +40,8 @@ class BaseTester:
|
||||
result = open(join(self.solution.testing_directory, "output.txt"), "r").read().strip().replace('\r\n', '\n')
|
||||
print("got result", result)
|
||||
if exists(join(self.path, "checker.py")):
|
||||
copyfile(join(self.path, filename + '.a'), join(self.path, 'expected.txt'))
|
||||
with open(join(self.path, 'expected.txt'), 'w') as fs:
|
||||
fs.write(self.predicted)
|
||||
call(f"docker run --name solution_{self.solution.id}_checker --volume=/sprint-data/solutions/{self.solution.id}:/app -t -d python:3.6", shell=True)
|
||||
code = call(f'docker exec -i solution_{self.solution.id}_checker sh -c "cd app && python checker.py"', shell=True, timeout=1)
|
||||
if code != 0:
|
||||
|
Loading…
Reference in New Issue
Block a user