|
3 | 3 | To run the test suite, execute: |
4 | 4 |
|
5 | 5 | ``` |
6 | | -just test |
| 6 | +ruby -Itest test/test_tracer.rb |
7 | 7 | ``` |
8 | 8 |
|
9 | | -This will run the ruby test file at `test/test_tracer.rb` which traces sample programs and compares their outputs to the fixtures in `test/fixtures`. |
| 9 | +The tester executes a number of sample programs in `test/programs` and compares their outputs to the fixtures in `test/fixtures`. |
| 10 | + |
| 11 | +To run the benchmark, execute: |
| 12 | + |
| 13 | +``` |
| 14 | +ruby test/benchmarks/run_benchmark.rb heavy_work |
| 15 | +``` |
| 16 | + |
| 17 | +# Code quality guidelines |
| 18 | + |
| 19 | +- Strive to achieve high code quality. |
| 20 | +- Write secure code. |
| 21 | +- Make sure the code is well tested and edge cases are covered. Design the code for testability. |
| 22 | +- Write defensive code and make sure all potential errors are handled. |
| 23 | +- Strive to write highly reusable code with routines that have high fan in and low fan out. |
| 24 | +- Keep the code DRY. |
| 25 | +- Aim for low coupling and high cohesion. Encapsulate and hide implementation details. |
| 26 | + |
| 27 | +# Code commenting guidelines |
| 28 | + |
| 29 | +- Document public APIs and complex modules. |
| 30 | +- Maintain the comments together with the code to keep them meaningful and current. |
| 31 | +- Comment intention and rationale, not obvious facts. Write self-documenting code. |
| 32 | +- When implementing specific formats, standards or other specifications, make sure to |
| 33 | + link to the relevant spec URLs. |
| 34 | + |
| 35 | +# Writing git commit messages |
| 36 | + |
| 37 | +The first line of the commit message should follow the "conventional commits" style: |
| 38 | +https://www.conventionalcommits.org/en/v1.0.0/ |
| 39 | + |
| 40 | +In the remaining lines, provide a short description of the implemented functionality. |
| 41 | +Provide sufficient details for the justification of each design decision if multiple |
| 42 | +approaches were considered. |
0 commit comments