continuwuity/docs/development/testing.mdx
Jade Ellis fa7f28003b
Some checks failed
Checks / Prek / Pre-commit & Formatting (pull_request) Failing after 1m38s
Documentation / Build and Deploy Documentation (pull_request) Successful in 4m3s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 6m38s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 6m46s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 6m39s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Failing after 11s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 15m41s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 15m52s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 21s
docs: New site 🎉
2025-11-15 20:25:54 +00:00

32 lines
1.4 KiB
Text

# Testing
## Complement
Have a look at [Complement's repository][complement] for an explanation of what
it is.
To test against Complement, with Nix (or [Lix](https://lix.systems) and
[direnv installed and set up][direnv] (run `direnv allow` after setting up the hook), you can:
* Run `./bin/complement "$COMPLEMENT_SRC"` to build a Complement image, run
the tests, and output the logs and results to the specified paths. This will also output the OCI image
at `result`
* Run `nix build .#complement` from the root of the repository to just build a
Complement OCI image outputted to `result` (it's a `.tar.gz` file)
* Or download the latest Complement OCI image from the CI workflow artifacts
output from the commit/revision you want to test (e.g. from main)
[here][ci-workflows]
If you want to use your own prebuilt OCI image (such as from our CI) without needing
Nix installed, put the image at `complement_oci_image.tar.gz` in the root of the repo
and run the script.
If you're on macOS and need to build an image, run `nix build .#linux-complement`.
We have a Complement fork as some tests have needed to be fixed. This can be found
at [continuwuation/complement](https://forgejo.ellis.link/continuwuation/complement)
[ci-workflows]:
https://forgejo.ellis.link/continuwuation/continuwuity/actions/?workflow=ci.yml&actor=0&status=1
[complement]: https://github.com/matrix-org/complement
[direnv]: https://direnv.net/docs/hook.html