# General testing and feedback
Unified tester for any language, for any exam
## Currently supported languages
- Python
- C++
# How to run
run the feedback module with the name of the tested file, and the appropriate configuration
## Examples
Python:
```
python -m feedback "tests/fixtures/integration/py/tested.py" "tests/fixtures/integration/py/py_config.json"
```
C++:
```
python -m feedback "tests/fixtures/integration/cpp/tested.cpp" "tests/fixtures/integration/cpp/cpp_config.json"
```
## Config file arhitecture
The config file uses JSON to serialise data.
### Tests
Specify a list of tests that should be ran, under the `"tests"` key, with each test name as a key and with a set of key-value pairs under that.
Every test requires the `"weight"` key, and some tests may require other parameters
#### Currently supported tests and parameters
- C++
- compile
- weight
- (optional) type: "o"
- (optional) warning_penalty: [0.0, 1.0]
- functionality
- weight
- functionality_executable
- weight
- comments
- weight
- static
- weight
- (optional) error_penalty: [0.0, 1.0]
- style
- style
- weight
- Python
- syntax
- weight
- functionality
- weight
- comments
- weight
### Execution
Under the `"execution"` you must specify the `"tester_file"` key and a value pointed to a file that runs the test, if you want to use the `"functionality"` test.
You can also specify a list of aditional files that need to be included in testing under `"additional_files"`.
### Example config
```
{
"tests": {
"compile": {
"weight": 0.1
},
"functionality": {
"weight": 0.6
},
"comments": {
"weight": 0.1
},
"static": {
"weight": 0.1
},
"style": {
"weight": 0.1,
"style": "google"
}
},
"execution":{
"tester_file": "run_code.cpp",
"additional_files": [
"test.h"
]
}
}
```
没有合适的资源?快使用搜索试试~ 我知道了~
PyPI 官网下载 | UoL-Autograder-0.2.4.tar.gz
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 66 浏览量
2022-01-17
06:10:40
上传
评论
收藏 146KB GZ 举报
温馨提示
共32个文件
py:11个
json:7个
txt:5个
资源来自pypi官网。 资源全名:UoL-Autograder-0.2.4.tar.gz
资源推荐
资源详情
资源评论
收起资源包目录
UoL-Autograder-0.2.4.tar.gz (32个子文件)
UoL-Autograder-0.2.4
MANIFEST.in 112B
PKG-INFO 751B
UoL_Autograder.egg-info
PKG-INFO 751B
requires.txt 21B
SOURCES.txt 917B
entry_points.txt 39B
top_level.txt 9B
dependency_links.txt 1B
feedback
general
__init__.py 4KB
contants.py 642B
signature.py 182B
cpp
cpp_eval_util.cpp 2KB
compile_examiner.py 1KB
__init__.py 17KB
cpp_eval_util.h 487B
empty_main.cpp 48B
json.hpp 804KB
__main__.py 962B
__init__.py 4KB
py
__init__.py 3KB
py_eval_util.py 7KB
lookup
py_runner_feedback.json 218B
cpp_static_warnings.json 783B
cpp_style_feedback.json 506B
cpp_compiler_feedback.json 2KB
comment_feedback.json 1KB
cpp_eval_feedback.json 406B
py_eval_feedback.json 557B
util
__init__.py 3KB
setup.cfg 86B
setup.py 2KB
README.md 2KB
共 32 条
- 1
资源评论
挣扎的蓝藻
- 粉丝: 13w+
- 资源: 15万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功