summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorankitjavalkar2015-06-09 16:42:21 +0530
committerankitjavalkar2015-06-17 14:48:06 +0530
commitdd716fce438898e7bbc0dfd262eb424a4a800011 (patch)
treead9422743891397f544f712665cb488a4c01ad00
parent4133466bf7e3ffee7d8075c4489feb8287665d6b (diff)
downloadonline_test-dd716fce438898e7bbc0dfd262eb424a4a800011.tar.gz
online_test-dd716fce438898e7bbc0dfd262eb424a4a800011.tar.bz2
online_test-dd716fce438898e7bbc0dfd262eb424a4a800011.zip
Multiple fixes to errors after code-rearrangement
- Remove evaluators from evaluators dir - Language IDs in forms has been fixed, all lower case - Remove spoken-tutorial database from settings
-rw-r--r--online_test/settings.py8
-rw-r--r--testapp/exam/bash_code_evaluator.py (renamed from testapp/exam/evaluators/bash_code_evaluator.py)0
-rw-r--r--testapp/exam/code_evaluator.py (renamed from testapp/exam/evaluators/code_evaluator.py)0
-rwxr-xr-xtestapp/exam/code_server.py2
-rw-r--r--testapp/exam/cpp_code_evaluator.py (renamed from testapp/exam/evaluators/cpp_code_evaluator.py)0
-rw-r--r--testapp/exam/evaluators/__init__.py0
-rw-r--r--testapp/exam/forms.py4
-rw-r--r--testapp/exam/java_code_evaluator.py (renamed from testapp/exam/evaluators/java_code_evaluator.py)0
-rw-r--r--testapp/exam/language_registry.py (renamed from testapp/exam/evaluators/language_registry.py)0
-rw-r--r--testapp/exam/python_code_evaluator.py (renamed from testapp/exam/evaluators/python_code_evaluator.py)0
-rw-r--r--testapp/exam/scilab_code_evaluator.py (renamed from testapp/exam/evaluators/scilab_code_evaluator.py)0
-rw-r--r--testapp/exam/settings.py12
-rw-r--r--testapp/exam/tests.py1
13 files changed, 10 insertions, 17 deletions
diff --git a/online_test/settings.py b/online_test/settings.py
index 9168b08..8916fe2 100644
--- a/online_test/settings.py
+++ b/online_test/settings.py
@@ -64,14 +64,6 @@ DATABASES = {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
},
- 'spoken_tutorial' : {
- 'ENGINE' : 'django.db.backends.mysql',
- 'NAME' : 'YOUR DATABASE',
- 'USER' : 'YOUR USERNAME',
- 'PASSWORD': 'YOUR PASSWORD',
- 'HOST' :'',
- 'PORT' :'',
- }
}
# Internationalization
diff --git a/testapp/exam/evaluators/bash_code_evaluator.py b/testapp/exam/bash_code_evaluator.py
index a468fd7..a468fd7 100644
--- a/testapp/exam/evaluators/bash_code_evaluator.py
+++ b/testapp/exam/bash_code_evaluator.py
diff --git a/testapp/exam/evaluators/code_evaluator.py b/testapp/exam/code_evaluator.py
index 381b2e8..381b2e8 100644
--- a/testapp/exam/evaluators/code_evaluator.py
+++ b/testapp/exam/code_evaluator.py
diff --git a/testapp/exam/code_server.py b/testapp/exam/code_server.py
index eb106a4..56dfff4 100755
--- a/testapp/exam/code_server.py
+++ b/testapp/exam/code_server.py
@@ -31,7 +31,7 @@ import re
import json
# Local imports.
from settings import SERVER_PORTS, SERVER_POOL_PORT
-from language_registry import set_registry
+from evaluators.language_registry import set_registry, get_registry
MY_DIR = abspath(dirname(__file__))
diff --git a/testapp/exam/evaluators/cpp_code_evaluator.py b/testapp/exam/cpp_code_evaluator.py
index 7242884..7242884 100644
--- a/testapp/exam/evaluators/cpp_code_evaluator.py
+++ b/testapp/exam/cpp_code_evaluator.py
diff --git a/testapp/exam/evaluators/__init__.py b/testapp/exam/evaluators/__init__.py
deleted file mode 100644
index e69de29..0000000
--- a/testapp/exam/evaluators/__init__.py
+++ /dev/null
diff --git a/testapp/exam/forms.py b/testapp/exam/forms.py
index b56e545..b7625be 100644
--- a/testapp/exam/forms.py
+++ b/testapp/exam/forms.py
@@ -17,8 +17,8 @@ languages = (
("select", "Select Language"),
("python", "Python"),
("bash", "Bash"),
- ("C", "C Language"),
- ("C++", "C++ Language"),
+ ("c", "C Language"),
+ ("cpp", "C++ Language"),
("java", "Java Language"),
("scilab", "Scilab"),
)
diff --git a/testapp/exam/evaluators/java_code_evaluator.py b/testapp/exam/java_code_evaluator.py
index 4367259..4367259 100644
--- a/testapp/exam/evaluators/java_code_evaluator.py
+++ b/testapp/exam/java_code_evaluator.py
diff --git a/testapp/exam/evaluators/language_registry.py b/testapp/exam/language_registry.py
index 76a23d7..76a23d7 100644
--- a/testapp/exam/evaluators/language_registry.py
+++ b/testapp/exam/language_registry.py
diff --git a/testapp/exam/evaluators/python_code_evaluator.py b/testapp/exam/python_code_evaluator.py
index 0c473cf..0c473cf 100644
--- a/testapp/exam/evaluators/python_code_evaluator.py
+++ b/testapp/exam/python_code_evaluator.py
diff --git a/testapp/exam/evaluators/scilab_code_evaluator.py b/testapp/exam/scilab_code_evaluator.py
index 392cd45..392cd45 100644
--- a/testapp/exam/evaluators/scilab_code_evaluator.py
+++ b/testapp/exam/scilab_code_evaluator.py
diff --git a/testapp/exam/settings.py b/testapp/exam/settings.py
index 5d3fb15..81605d9 100644
--- a/testapp/exam/settings.py
+++ b/testapp/exam/settings.py
@@ -20,10 +20,10 @@ SERVER_TIMEOUT = 2
URL_ROOT = ''
code_evaluators = {
- "python": "evaluators.python_code_evaluator.PythonCodeEvaluator",
- "c": "evaluators.c_cpp_code_evaluator.CCPPCodeEvaluator",
- "cpp": "evaluators.c_cpp_code_evaluator.CCPPCodeEvaluator",
- "java": "evaluators.java_evaluator.JavaCodeEvaluator",
- "bash": "evaluators.bash_evaluator.BashCodeEvaluator",
- "scilab": "evaluators.scilab_evaluator.ScilabCodeEvaluator",
+ "python": "python_code_evaluator.PythonCodeEvaluator",
+ "c": "c_cpp_code_evaluator.CCPPCodeEvaluator",
+ "cpp": "c_cpp_code_evaluator.CCPPCodeEvaluator",
+ "java": "java_evaluator.JavaCodeEvaluator",
+ "bash": "bash_evaluator.BashCodeEvaluator",
+ "scilab": "scilab_evaluator.ScilabCodeEvaluator",
}
diff --git a/testapp/exam/tests.py b/testapp/exam/tests.py
index 7a8d30c..f4cff3e 100644
--- a/testapp/exam/tests.py
+++ b/testapp/exam/tests.py
@@ -20,6 +20,7 @@ def setUpModule():
# create a quiz
Quiz.objects.create(start_date='2014-06-16', duration=30, active=False,
+ attempts_allowed=-1, time_between_attempts=0,
description='demo quiz', pass_criteria=40,
language='Python', prerequisite=None)