-
Notifications
You must be signed in to change notification settings - Fork 2
Development
trhgquan edited this page Aug 3, 2022
·
3 revisions
Adding a new test case named 19120338
:
- Payload: write test payloads to
tests/input/19120338.inp
- Output: write expected output to
tests/output/19120338.out
Running tests:
make
make init_test
-
make test
(or silent mode:make test_silent
- without progress bar)
- For step 1:
Makefile
will compile a new binary. - For step 2:
Makefile
will copy that new binary to thetests/
folder. - For step 3: The test module
tests/test.pl
will be triggered: first it read the input insidetests/input/<testname>.inp
then compare with the output insidetests/output/<testname>.out
. This will run until all test cases are checked and any failed case will break the procedure immediately.
We support code coverage reports! Just make sure you have lcov
installed.
make gcov
make init_test
make test
make lcov
make generate-coverage-report
Coverage Report will be automatically generated inside coverage/
We require your code to be formatted with clang-format
before going further.
Follow these steps:
Install clang-format
:
sudo apt-get install clang-format
Run checks:
make lint
If there are any linting errors, run make format
to format it.
make format
As described in jh.pl
, this file checks if any binary or coverage reports are mistakenly visible to Git. This prevents pushing garbage to the remote.