Commit Graph

92 Commits

Author SHA1 Message Date
Kévin Commaille
de60a24602 Remove __test feature 2022-07-07 11:26:49 +02:00
Kévin Commaille
dd6a902240 test(sdk): Move integration tests 2022-07-04 16:22:20 +02:00
Kévin Commaille
4eb1337dc8 ci: Remove whitespaces in config file 2022-07-04 16:22:19 +02:00
Ivan Enderlin
68b6c19dd4 test: Ensure all crates members of the workspace are compiled & tested. 2022-06-23 14:10:31 +02:00
Ivan Enderlin
1604f24136 chore(test): Fix YAML. 2022-06-22 16:03:37 +02:00
Ivan Enderlin
2ffcc1a415 chore: Use [m] as an alias for matrix-sdk. 2022-06-22 16:03:37 +02:00
Ivan Enderlin
54acd314cc chore(test): Move the wasm workflow inside the ci workflow. 2022-06-22 16:03:37 +02:00
Ivan Enderlin
0436eb9349 chore(ci): Rephrase a little bit the Github Actions steps. 2022-06-22 16:03:37 +02:00
Ivan Enderlin
8db58986fb chore(bindings): Move crypto-nodejs and crypto-js into the bindings/ directory.
`matrix-sdk-crypto-nodejs` and `matrix-sdk-crypto-js` are no longer
default members of the Cargo virtual workspace. The Github Actions
workflows for the bindings now live in a `bindings_ci.yml` files
(ideally, it should be in a subdirectory,
`.github/workflows/bindings/ci.yml` but it doesn't work).
2022-06-22 11:54:49 +02:00
Ivan Enderlin
6ad323bc4e test: Run tests faster with nextest
test: Run tests faster with `nextest`
2022-06-22 09:56:02 +02:00
Ivan Enderlin
3bfc68d476 test: Add missing cargo-nextest installation.
This patch also changes the step's name from Clippy to Test.
2022-06-22 09:26:51 +02:00
Ivan Enderlin
eb33333925 test: Run doctests manually.
`cargo-nextest` doesn't support doctests for now, so we must run them
“manually” by running a separate `cargo test --doc` command.
2022-06-22 09:26:51 +02:00
Ivan Enderlin
399862d955 test: Run tests faster with nextest.
> [`cargo-nextest`](https://nexte.st/index.html) is a next-generation
> test runner for Rust projects.

This patch installs and uses `nextest` to run our own tests.

Comparing `cargo test` and `cargo nextest` with hyperfine provides the
following results:

```sh
$ hyperfine 'cargo test --workspace' 'cargo nextest run --workspace && cargo test --doc'
Benchmark 1: cargo test --workspace
  Time (mean ± σ):     51.785 s ±  2.066 s    [User: 183.471 s, System: 10.563 s]
  Range (min … max):   49.151 s … 56.641 s    10 runs

Benchmark 2: cargo nextest run --workspace && cargo test --doc
  Time (mean ± σ):     44.556 s ±  0.894 s    [User: 192.213 s, System: 11.441 s]
  Range (min … max):   43.170 s … 45.762 s    10 runs
```

Benchmark 2 is 1.16 times faster than Benchmark 1.
2022-06-22 09:26:07 +02:00
Ivan Enderlin
8b2237fa7a Merge branch 'main' into feat-crypto-js-next 2022-06-21 11:38:48 +02:00
Ivan Enderlin
c56ab5928c test(crypto-js): Add a workflow to test matrix-sdk-crypto-js. 2022-06-14 16:34:08 +02:00
Ivan Enderlin
073fb45580 feat(crypto-nodejs): Define Node.js versions policy.
We now support only “current”, “active” or “maintenance” versions
according to https://nodejs.org/en/about/releases/, which are
compatible with NAPI v6.
2022-06-14 16:05:01 +02:00
Ivan Enderlin
3833d35348 chore(crypto-nodejs): Drop Node.js v12.17.
There is a segfault with `napi-rs` and Node.js in v12.17. It's an old
version, it may be fair to drop its support for now. Let's see if
people would need it in the future, we may work on `napi-rs` to fix
this bug in case it's really necessary.
2022-06-14 16:05:01 +02:00
Ivan Enderlin
1b2c644277 test(crypto-nodejs): Set up CI to run the test suites. 2022-06-09 11:34:16 +02:00
Benjamin Kampmann
a7b8cc5810 ci: remove unnecessary dependency 2022-04-29 17:28:51 +02:00
Benjamin Kampmann
9b6fe94bc8 ci(tooling): Improved Style Checking
- separate Styles from ci.yaml into its own for clarity
- extend pre-commit config with other useful defaults
- move clippy, tests and typos into a push-based pre-commit
2022-04-29 14:50:12 +02:00
Damir Jelić
691ea2d138 ci(crypto): Test the crypto crate features when we run the CI 2022-03-10 13:52:31 +01:00
Jonas Platte
804c8e6c43 ci: Add test and test-features xtask commands 2022-03-04 10:59:17 +01:00
Jonas Platte
beb4ecb581 ci: Remove mentions of non-existant matrix variables 2022-03-04 10:59:17 +01:00
Jonas Platte
e136199bfd ci: Don't run check / build before test
It is redundant.
2022-03-04 10:59:17 +01:00
Benjamin Kampmann
fd6f4385d4 Merge remote-tracking branch 'origin/main' into ben-splitting-out-store-impls 2022-03-03 12:57:00 +01:00
Jonas Platte
2182ebdd16 ci: Fix toolchain installation job name inconsistencies 2022-03-03 11:10:30 +01:00
Jonas Platte
439081e1db ci: Move wasm and appservice into separate workflows
… to reduce the size of `ci.yml` and to allow more fine-grained retries.
2022-03-03 11:10:29 +01:00
Jonas Platte
1968ae60aa ci: Fix inconsistencies in workflow yml formatting 2022-03-03 11:10:29 +01:00
Jonas Platte
b7a4ca4cff Create an xtask crate for workspace task automation
Initially covering:

* Building docs
* Nightly CI jobs
2022-03-03 11:10:28 +01:00
Jonas Platte
6e091dd5b8 ci: Use Swatinem/rust-cache@v1 instead of actions/cache@v2
Simplifies the cache configuration and could also improve build times by
disabling incremental compilation and potentially caching fewer things
or using a better cache key.
2022-03-03 11:04:07 +01:00
Jonas Platte
012954e7f4 ci: Remove --all flag from cargo fmt arguments
It is only relevant for non-workspace path dependencies.
2022-03-02 14:34:22 +01:00
Benjamin Kampmann
102f960d25 chore(ci): limit CI to pull-requests & push main
Running CI on every push means running it twice for any PR as well as commit on branches that aren't PRs. This limits the CI run to pull-requests against main and pushes to main directly, removing unnecessary workload for the CI and making PRs CI faster.
2022-03-02 13:01:18 +01:00
Benjamin Kampmann
c2bb1b9ad1 remove unneded braces in ci 2022-03-01 11:20:04 +01:00
Benjamin Kampmann
56b3b2cec6 minor fix in ci 2022-02-25 16:11:32 +01:00
Benjamin Kampmann
06c9b1abe3 fixing proepr cargo build call 2022-02-25 15:23:04 +01:00
Benjamin Kampmann
9386e9df51 fixing name path 2022-02-24 16:56:14 +01:00
Benjamin Kampmann
4d6d13b9c8 fixing some clippies and wrong package naming 2022-02-24 15:40:24 +01:00
Benjamin Kampmann
259ba3b794 refactor CI tests 2022-02-24 15:14:54 +01:00
Benjamin Kampmann
21887877da chore(CI): limit CI runs to non-draft PRs and manual dispatching 2022-02-23 16:04:05 +01:00
Benjamin Kampmann
fa60881e2d disable broken test 2022-02-02 20:34:52 +01:00
Benjamin Kampmann
9ff4609f3d testing emcc versions 2021-12-27 23:35:21 +01:00
Benjamin Kampmann
3cde28a438 trying older emscripten 2021-12-27 21:37:37 +01:00
Benjamin Kampmann
574893368b refine wasm tests 2021-12-22 12:32:59 +01:00
Benjamin Kampmann
1f5a084ccf don't fail fast 2021-12-22 11:38:52 +01:00
Benjamin Kampmann
8dda7ea8fa please consider all includes 2021-12-22 11:19:39 +01:00
Benjamin Kampmann
e619cc1eb7 don't combine 2021-12-22 10:59:17 +01:00
Benjamin Kampmann
1a206ff36c let them all run out 2021-12-16 18:46:00 +01:00
Benjamin Kampmann
afe7d055a1 [ci] fix syntax 2021-12-16 18:24:31 +01:00
Benjamin Kampmann
9d4d8667ff latest and node 2021-12-16 17:14:03 +01:00
Benjamin Kampmann
8feab722f8 [CI] dynamic node version 2021-12-16 11:35:24 +01:00