You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

75 lines
1.9 KiB

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
jobs:
lint:
strategy:
matrix:
toolchain:
- nightly-2023-06-01
runs-on: ubuntu-latest
container: devkitpro/devkitarm
steps:
- name: Checkout branch
uses: actions/checkout@v2
- uses: ./.github/actions/setup
with:
toolchain: ${{ matrix.toolchain }}
- name: Check formatting
run: cargo fmt --all --verbose -- --check
- name: Run clippy
run: cargo 3ds clippy --color=always --verbose --all-targets
test:
strategy:
matrix:
toolchain:
# Oldest supported nightly
- nightly-2023-06-01
- nightly
continue-on-error: ${{ matrix.toolchain == 'nightly' }}
runs-on: ubuntu-latest
steps:
- name: Checkout branch
uses: actions/checkout@v3
- uses: ./.github/actions/setup
with:
toolchain: ${{ matrix.toolchain }}
- name: Build and run tests (unit + integration)
uses: ./.github/actions/test
- name: Build and run doc tests
# Let's still run doc tests even if lib/integration tests fail:
if: ${{ !cancelled() }}
env:
# This ensures the citra logs and video output gets put in a directory
# where we can upload as artifacts
RUSTDOCFLAGS: " --persist-doctests target/armv6k-nintendo-3ds/debug/doctests"
uses: ./.github/actions/test
with:
args: --doc
- name: Upload citra logs and capture videos
uses: actions/upload-artifact@v3
# We always want to upload artifacts regardless of previous success/failure
if: ${{ !cancelled() }}
with:
name: citra-logs-${{ matrix.toolchain }}
path: |
target/armv6k-nintendo-3ds/debug/**/*.txt
target/armv6k-nintendo-3ds/debug/**/*.webm