summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoradityacp2016-10-25 15:03:27 +0530
committeradityacp2016-10-25 15:03:27 +0530
commit450954e5140b5c9a447127508e324841d311386a (patch)
treebbcd89d40d241be5b9d9ed5a7f721504e25d228a
parent3fcf7c6772bf6a3a91c4348a309e80ccc4592bba (diff)
downloadonline_test-450954e5140b5c9a447127508e324841d311386a.tar.gz
online_test-450954e5140b5c9a447127508e324841d311386a.tar.bz2
online_test-450954e5140b5c9a447127508e324841d311386a.zip
creation of user output directory from code evaluator
-rw-r--r--yaksh/code_evaluator.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/yaksh/code_evaluator.py b/yaksh/code_evaluator.py
index 870a67f..e2097b0 100644
--- a/yaksh/code_evaluator.py
+++ b/yaksh/code_evaluator.py
@@ -94,6 +94,9 @@ class CodeEvaluator(object):
# Private Protocol ##########
def setup(self):
+ if self.in_dir:
+ if not os.path.exists(self.in_dir):
+ os.mkdir(self.in_dir)
self._change_dir(self.in_dir)
def safe_evaluate(self, user_answer, test_case_data, file_paths=None):