kuroko
v1.1.0
Published
Simple local judgement tool
Downloads
14
Maintainers
Readme
Kuroko
ジャッジメントですの!
Simple local offline judgement tool for competitive programming.
Installation
# npm
npm install -g kuroko
# yarn
yarn global add kuroko
Usage
Basic usage:
$ echo 5 | ./factorial
120
$ # Create test cases
$ echo 5 > 1.in
$ echo 120 > 1.out
$ # Run test
$ kuroko factorial
success - Test case `1.in` => `1.out` correct
Use scaffolding:
$ # Create test inputs
$ echo foo > foo.in
$ echo bar > bar.in
$ echo baz > baz.in
$ # Let's make echo script
$ cat <<'EOF' > echo.sh && chmod +x echo.sh
#!/bin/sh
read line
echo $line
EOF
$ # We can use `cat` command to verify script
$ kuroko --scaffold=cat ./echo.sh
success - Test case `bar.in` => `cat < bar.in` correct
success - Test case `baz.in` => `cat < baz.in` correct
success - Test case `foo.in` => `cat < foo.in` correct