diff options
author | sssooonnnggg <kevinsong@lilith.com> | 2023-05-17 07:06:41 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-16 16:06:41 -0700 |
commit | ea7cfcd5911c187f9ab6d9c374c60a054c79d01a (patch) | |
tree | 58636105939c4c1c98613c880a34647f111e3c8f | |
parent | 067553156ace23d7eaf480aacdcdedb3191a2660 (diff) | |
download | flatbuffers-ea7cfcd5911c187f9ab6d9c374c60a054c79d01a.tar.gz flatbuffers-ea7cfcd5911c187f9ab6d9c374c60a054c79d01a.tar.bz2 flatbuffers-ea7cfcd5911c187f9ab6d9c374c60a054c79d01a.zip |
chore: add rust windows test to CI, fix RustTest.bat (#7963)
Co-authored-by: Derek Bailey <derekbailey@google.com>
-rw-r--r-- | .github/workflows/build.yml | 13 | ||||
-rw-r--r-- | tests/RustTest.bat | 17 |
2 files changed, 21 insertions, 9 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 36e6a3bd..23f4bb33 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -444,14 +444,23 @@ jobs: # gradlew run: gradle jvmMainClasses jvmTest jsTest jsBrowserTest - build-rust: - name: Build Rust + build-rust-linux: + name: Build Rust Linux runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - name: test working-directory: tests run: bash RustTest.sh + + build-rust-windows: + name: Build Rust Windows + runs-on: windows-2019 + steps: + - uses: actions/checkout@v3 + - name: test + working-directory: tests + run: ./RustTest.bat build-python: name: Build Python diff --git a/tests/RustTest.bat b/tests/RustTest.bat index 236cd9d7..56f43f2d 100644 --- a/tests/RustTest.bat +++ b/tests/RustTest.bat @@ -15,16 +15,19 @@ rem limitations under the License. rem Compile then run the Rust test. -cd rust_usage_test +cd rust_serialize_test +cargo run -- --quiet || exit /b 1 + +cd ../rust_no_std_compilation_test +rustup install nightly +rustup component add rust-src --toolchain nightly +rustup target add thumbv7m-none-eabi +cargo +nightly build || exit /b 1 + +cd ../rust_usage_test cargo test -- --quiet || exit /b 1 cargo run --bin=flatbuffers_alloc_check || exit /b 1 cargo run --bin=flexbuffers_alloc_check || exit /b 1 cargo run --bin=monster_example || exit /b 1 cd .. -cd rust_no_std_compilation_test -rustup install nightly -rustup component add rust-src --toolchain nightly -rustup target add thumbv7m-none-eabi -cargo build || exit /b 1 -cd .. |