53 Commits

Author SHA1 Message Date
Nikolay Arhipov
53cf0cc3af
Add support for PS Vita (armv7-sony-vita-newlibeabihf) (#359) 2023-05-07 10:35:48 +00:00
Joe Richey
03defac1e5
ci: use minimal permissions for Github Actions (#351)
Fixes #348

we only need to read the contents of the repo to run our tests, no other
permissions are needed, as we currently do not publish via our CI jobs.

Signed-off-by: Joe Richey <joerichey@google.com>
2023-03-24 19:30:06 -07:00
Joe Richey
5042b09742 Update wasm-pack
Signed-off-by: Joe Richey <joerichey@google.com>
2023-03-24 14:23:06 -07:00
Joe Richey
6cd1a12ef2 Disable cross build/tests on Android
Cross is currently broken on Android, see https://github.com/cross-rs/cross/issues/1222

The bug is fixed on master, but a new release of cross hasn't come out
yet.

Signed-off-by: Joe Richey <joerichey@google.com>
2023-03-23 18:04:35 -07:00
Joseph Richey
75252bca49
ci: Fix the fuchsia tests (#343)
The target triple name was changed in https://github.com/rust-lang/rust/pull/106429

While `rustc` known the old spelling of the triple, `rustup` does not,
so the toolchain download was not working.

Signed-off-by: Joe Richey <joerichey@google.com>
2023-03-09 20:35:51 -08:00
Joseph Richey
41b89814e3
Allow Edge tests to fail (#339)
Window's `msedgedriver` seems to be unreliable, as port binding will
occasionally fail. Instead of wasting time trying to debug this, just
let the tests fail.

We take a similar approch for Safari's webdriver, we will allow the
tests to fail, but will hopefully see when they start succeeding (when
Safari fixes the COOP bug).

Signed-off-by: Joe Richey <joerichey@google.com>
2023-02-23 11:56:11 -08:00
Joseph Richey
74a2021ee1
ci: Don't use rust-cache for Cross Build/Link (#338)
I think the caching isn't interacting well with the libc build script.

Lets see if this fixes things.

Signed-off-by: Joe Richey <joerichey@google.com>
2023-02-22 13:01:58 -08:00
Joe Richey
8d8a882eb6 Move Web Tests to Ubuntu 22.04
Signed-off-by: Joe Richey <joerichey@google.com>
2023-02-08 17:12:14 -08:00
Joe Richey
a2b48866b9 Reenable cross build/link tests and update cross
My not caching the build results, we should hopefuly prevent the linking
errors we were seeing before.

Signed-off-by: Joe Richey <joerichey@google.com>
2023-02-08 17:02:53 -08:00
Artyom Pavlov
698a6d1a06
Disable cross build/link tests (#328) 2023-01-04 00:44:52 -08:00
Kian-Meng Ang
ea5ef25714
Fix typos (#327) 2023-01-04 06:58:29 +00:00
Florian Bartels
993505c17f
Enable tests for QNX/Neutrino, integrate new libc version 2022-12-23 07:50:53 +01:00
Joe Richey
f096c04523 Update all runners to macOS 12
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
2e66e5921f Programaticly select iOS simulator Runtime/Device
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
62e697f9ca Run web tests on 20.04
This is necessary to get Firefox to work.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
b04bd03e14 Explicitly use windows-2022
Currently this is the same as `windows-latest` so this is not a
functional change.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
9d4a91f9a1 Remove workaround not needed on Ubuntu 22.04
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
941c2fff69 Update tests to run on Ubuntu 22.04 (instead of 20.04)
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
5ddec2a8f4 Check OS using runner.os instead of matrix.os
This makes it easier to later update the OS verions

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:09:06 -07:00
Joe Richey
8e4ecdb72f Use "host" instead of "target" in Web Tests
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-31 00:08:59 -07:00
Joseph Richey
5a4a8eafe5
Fix iOS simulator CI (#323)
The upgrade to macOS 12 broke this iOS simulator CI (as support for the
iPhone 7 was dropped I think).

We should have a follow up PR to see if we can just test against a more
recent iPhone.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-30 20:31:26 -07:00
Joe Richey
c3d9797a0b Just Pin Versions for compiled downloads
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-25 23:44:36 -07:00
Joe Richey
03f6688195 Cleanup other binary download steps
Be consistent and always use wget

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-25 23:31:56 -07:00
Joe Richey
f84a061151 Add additional Web Tests
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-25 23:05:32 -07:00
Thom Chiovoloni
e32ea822c3
Add tvOS and watchOS to CI 2022-10-24 23:24:56 -07:00
Joe Richey
4917673cd2 Break up Tier 3 builds
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-24 01:56:17 -07:00
Joe Richey
b35add2bb7 Uptade to Swatinem/rust-cache@v2
Also move the cache step to be right before we start running cargo
commands.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-24 01:56:17 -07:00
Joe Richey
a91ad48d8c Update to actions/checkout@v3
Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-24 01:56:17 -07:00
Joe Richey
b1da11b850 Run iOS Simulator Tests
This builds, links, and runs the tests on `x86_64-apple-ios` using
[`dinghy`](https://github.com/sonos/dinghy). It moves the targets
which only Build/Link to their own job.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-24 01:56:10 -07:00
Joe Richey
14b461fa39 Make job names consistent
This makes it easier to tell on which targets we:
  - Build
  - Link
  - Run

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-24 01:50:03 -07:00
Joe Richey
762c95dd7a Move from actions-rs/toolchain to dtolnay/rust-toolchain
The current action we are using is unmantained:
https://github.com/actions-rs/toolchain/issues/216

This replacement is faster, smaller, and more cachable.

We can also completely remove the toolchain step when testing with
cross, as cross handles configuration of its own toolchain.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-23 21:32:21 -07:00
Joe Richey
1d371ef5e2 Add wasm64-unknown-unknown support
We can build and link just fine, but we cannot actually run the tests as
`wasm-bindgen-test-runner` hasn't yet added support.

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-23 13:47:00 -07:00
Brian Smith
84883207b9 CI: On Nightly toolchains, test the benchmarks instead of just building them.
`cargo test` will run one iteration of each benchmark to provide evidence
that they don't fail in an obvious way (e.g. unintended panics).
2022-10-22 23:16:50 -07:00
Joseph Richey
ce5c2d96ac
Test emscripten via Cross (#302)
Part of addressing #275 

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-22 13:23:49 -07:00
Joseph Richey
d2ca7695e3
Fix Solaris/OpenBSD/Dragonfly build and re-enable CI (#301)
Fixes #216 

This also adds two minor CI improvements:
  - Do a full link on `freebsd`
  - Build, Link, but don't run on `illumos`
  - Use the stable toolchain for our Tier 2 Build-only targets
  - Build (via `build-std`) for Tier 3 targets: `openbsd`, `dragonfly`, `haiku`

Signed-off-by: Joe Richey <joerichey@google.com>
2022-10-22 13:22:38 -07:00
Brian Smith
47a59dda25
Add getrandom_uninit_slice(dest: &mut [MaybeUninit<u8>]) -> .... (#291)
* Add `getrandom_uninit(dest: &mut [MaybeUninit<u8>]) -> ...`.

Add a public API for filling an `&mut [MaybeUninit<u8>]`. This will primarily
serve as the building block for more typeful APIs for constructing random
arrays.

Increase the MSRV to 1.36, as `MaybeUninit` was added in that release.

Fixes #226.

* Revert testing changes

Signed-off-by: Joe Richey <joerichey@google.com>

* Allow rdrand tests to work with new implementation

Signed-off-by: Joe Richey <joerichey@google.com>

* Add Additional benchmarks and buffer size

Signed-off-by: Joe Richey <joerichey@google.com>

* Use pointer casts instead of transmute

Signed-off-by: Joe Richey <joerichey@google.com>

* Avoid initializing the buffer in `getrandom_uninit` benchmarks.

* Benchmarks: Consume the result in `black_box`.

Signed-off-by: Joe Richey <joerichey@google.com>
Co-authored-by: Joe Richey <joerichey@google.com>
2022-10-20 19:09:20 -07:00
Артём Павлов [Artyom Pavlov]
0830ba66be Disable Solaris CI job 2022-03-26 01:19:56 +03:00
Mark Drobnak
d40ec2c7e4
Add support for the Nintendo 3DS (armv6k-nintendo-3ds) (#248) 2022-03-25 16:26:05 +00:00
Артём Павлов [Artyom Pavlov]
f49f083412 fix cross tests 2022-01-29 18:48:38 +03:00
Stewart Mackenzie
ec445bb0ac
Added x86_64-unknown-hermit support (#236) 2021-12-07 14:48:30 +00:00
Tomoaki Kawada
f5e33009ed
Add SOLID target support (#235) 2021-11-30 00:21:36 +00:00
Joseph Richey
922d1de82d
Fix Solaris CI (#216)
The new target is called `x86_64-pc-solaris`, but `cross` doesn't
support that yet, so just use `sparcv9-sun-solaris`.

See the following issues for more info:
  https://github.com/rust-lang/rust/issues/85098
  https://github.com/rust-lang/rust/pull/82216

Signed-off-by: Joe Richey <joerichey@google.com>
2021-05-14 12:04:30 +03:00
Joe Richey
2cfbd8ee60
Modify doc tests to set docsrs
Signed-off-by: Joe Richey <joerichey@google.com>
2021-01-19 02:46:38 -08:00
Joe Richey
03cc4f704d Cache Cargo index and Rust build directory
Signed-off-by: Joe Richey <joerichey@google.com>
2021-01-17 00:28:30 -08:00
Joseph Richey
347a300215
Add test for custom RNG handler (#197)
See #194

This uses the fact that `wasm32-unknown-unknown` is an "unsupported" target. This means we can use the `"custom"` feature to define a custom handler, and then write tests to make sure that function is called.
2021-01-05 02:00:21 -08:00
Joseph Richey
9d7a76c19e
Add Emscripten tests (#196)
See #194 

This installs (and caches) the emsdk toolchain at the last version compatible w/ stable rust. It also tests on both asmjs and wasm32, uses node by default, and works around an asm.js bug.
2021-01-05 01:38:44 -08:00
Joe Richey
7b8f2ba952 Note that installed binaries are precompiled 2021-01-03 21:26:32 -08:00
Joe Richey
7687498160 Only test macOS on stable
Most of the advantages from testing various Rust versions already come
from running those tests on Linux and Windows. There's very little
gain from also running these tests on macOS, while macOS jobs are the
slowest to schedule.

Signed-off-by: Joe Richey <joerichey@google.com>
2021-01-03 20:46:12 -08:00
Joe Richey
ea73f5a975 Update CI
- Cleanup `tests.yml`
- Add better binary downloads
- Add minimal dependancies check
- Add tests for `custom` feature
- Build/Link for iOS
- Run cross tests on aarch64 linux and Android
- Link on Solaris and Netbsd
- Test wasm code on Node, Chrome, Firefox
- Test WASI
- No need for RDRAND feature on VxWorks

Signed-off-by: Joe Richey <joerichey@google.com>
2021-01-03 20:46:12 -08:00
Joe Richey
d5186e0c86 Add Clippy msrv configuration file
This allows us to automatically ignore lints that are
incompatible with our MSRV.

Signed-off-by: Joe Richey <joerichey@google.com>
2021-01-03 20:46:12 -08:00