-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
# Objective - ~~Running examples on Linux in CI timeout~~Linux is back! - But hey we can run examples on windows too! ## Solution - Run examples on windows daily - I also added a 30 minutes timeout so that when it explodes, it doesn't explodes in 6 hours (the default timeout) - And simplified the linux examples by not requiring a custom feature set
- Loading branch information
Showing
4 changed files
with
105 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
name: validation jobs | ||
|
||
on: | ||
push: | ||
branches: | ||
- staging | ||
- trying | ||
- main | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
build-and-install-on-iOS: | ||
runs-on: macos-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
override: true | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
target | ||
key: ${{ runner.os }}-ios-install-${{ matrix.toolchain }}-${{ hashFiles('**/Cargo.lock') }} | ||
|
||
- name: Add iOS targets | ||
run: rustup target add aarch64-apple-ios x86_64-apple-ios | ||
|
||
- name: Build and install iOS app in iOS Simulator. | ||
run: cd examples/ios && make install | ||
|
||
build-android: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.cargo/bin/ | ||
~/.cargo/registry/index/ | ||
~/.cargo/registry/cache/ | ||
~/.cargo/git/db/ | ||
target/ | ||
key: ${{ runner.os }}-cargo-build-android-${{ hashFiles('**/Cargo.toml') }} | ||
|
||
- name: Uninstall android-31 | ||
run: $ANDROID_SDK_ROOT/cmdline-tools/latest/bin/sdkmanager --uninstall "platforms;android-31" | ||
|
||
- name: Install Android targets | ||
run: rustup target add aarch64-linux-android armv7-linux-androideabi | ||
|
||
- name: Install Cargo APK | ||
run: cargo install --force cargo-apk | ||
|
||
- name: Build APK | ||
run: cargo apk build --example android | ||
|
||
run-examples-on-windows: | ||
runs-on: windows-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
|
||
- uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.cargo/bin/ | ||
~/.cargo/registry/index/ | ||
~/.cargo/registry/cache/ | ||
~/.cargo/git/db/ | ||
target/ | ||
key: ${{ runner.os }}-windows-run-examples-${{ hashFiles('**/Cargo.toml') }} | ||
|
||
- name: Build bevy | ||
run: | | ||
cargo build --features "bevy_ci_testing" | ||
- name: Run examples | ||
shell: bash | ||
run: | | ||
for example in .github/example-run/*.ron; do | ||
example_name=`basename $example .ron` | ||
echo "running $example_name - "`date` | ||
time CI_TESTING_CONFIG=$example cargo run --example $example_name --features "bevy_ci_testing" | ||
sleep 10 | ||
done |