Skip to content

Commit e454c9a

Browse files
alehander92zah
authored andcommitted
docs: add a contributions/style guide page and expand testing section, addressing Zahary's comments
1 parent c0b2ed5 commit e454c9a

File tree

3 files changed

+37
-1
lines changed

3 files changed

+37
-1
lines changed

docs/book/src/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
## Summary
22

33
- [Introduction](./introduction.md)
4+
- [Contributions](./contributions.md)
45

56
## Usage guide
67

docs/book/src/contributions.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
## Contributions
2+
3+
We are welcoming contributors!
4+
5+
If you want to fix something smaller, feel free to open an issue or a a PR!
6+
7+
If you want to make a bigger change, or to add a new feature, please open first an issue, or a discussion in our Github repo,
8+
or discuss it with us in the chat server in Discord.
9+
10+
### Style guide
11+
12+
For Rust, we are using `cargo fmt` to autoformat our code, and `cargo clippy` with some custom allow/deny rules inside the code.
13+
We have a `cargo clippy` check in our CI, but one can also run it locally.
14+
15+
For Nim, we still haven't written down a guide or list of rules and principles that we agree on, so this is something that we hope to do.
16+
We might also link to an existing document.
17+
18+
### Commits/Pull Requests
19+
20+
We are using [the "Conventional Commits" strategy](https://www.conventionalcommits.org/).
21+
22+
We use or are ok with using more "types", not only those included by default in their official page: e.g. `cleanup:`, `tooling:`, `examples:` etc.
23+
24+
We use `git rebase`, not merge and currently use the github pull requests as the main way to add code. Any pull request would need at least one review
25+
from someone from the CodeTracer team.

docs/book/src/introduction.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,17 @@ TODO:
4747
4848
### Building and running the tests
4949

50-
Coming soon!
50+
Currently, you can run the db-backend (Rust) tests:
51+
52+
```bash
53+
# inside src/db-backend:
54+
cargo test --release --bin db-backend # test most cases: non-ignored
55+
cargo test --release --bin db-backend -- --ignored # test the ignored cases: ignored by default as they're slower
56+
```
57+
58+
We are planning on restoring the e2e tests for db-backend: currently they don't work,
59+
as they were created originally with native language test programs in our older repo targetting the rr-backend.
60+
We hope to write a lot more e2e tests, as we haven't covered most features/cases.
5161

5262
### Enabling `cachix`
5363

0 commit comments

Comments
 (0)