Skip to content

Latest commit

 

History

History
63 lines (40 loc) · 1.85 KB

File metadata and controls

63 lines (40 loc) · 1.85 KB

Thanks for your interest in contributing to ouch!

Table of contents:

Code of Conduct

We follow the Rust Official Code of Conduct.

I want to ask a question or provide feedback

Create an issue or go to Ouch Discussions.

Adding a new feature

Before opening the PR, open an issue to discuss your addition, this increases the chance of your PR being accepted.

PRs

  • Pass all CI checks.
  • After opening the PR, add a CHANGELOG.md entry.

CI Tests

The CI tests will run for a combination of features, --no-default-features will also be tested.

Dealing with UI tests

We use snapshots to do UI testing and guarantee a consistent output, this way, you can catch accidental changes or see what output changed in the PR diff.

  • Run tests with cargo insta (requires cargo install cargo-insta):
cargo insta test
# Or, if you only want to run UI tests
cargo insta test -- ui
# Sometimes, you might have to run UI tests with different feature flags
cargo insta test --no-default-features -- ui
  • You can also use the --profile fast flag to trade some compile time for faster tests (usually worth it):
cargo test --profile fast
cargo insta test --profile fast -- ui
  • If some UI test failed, you should review them:
cargo insta review
  • After addressing all, you should be able to git add and commit accordingly.

NOTE: Sometimes, you'll have to run these two commands multiple times.