fix: non integer image position #181
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
name: Rust | |
on: | |
push: | |
branches: ["master"] | |
pull_request: | |
branches: ["master"] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
RUSTFLAGS: "--deny warnings" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install wasm32-unknown-unknown target | |
run: rustup target add wasm32-unknown-unknown | |
# With no feature. Target: normal & wasm & wasm-bindgen | |
- name: Build | |
run: cargo build --verbose | |
- name: Build in wasm | |
run: cargo build --verbose --target wasm32-unknown-unknown | |
- name: Build in wasm-bindgen | |
run: cargo build --verbose -F wasm-bindgen --target wasm32-unknown-unknown | |
# With feature `svg`. Target: normal & wasm & wasm-bindgen | |
- name: Build with `svg` | |
run: cargo build --verbose -F svg | |
- name: Build with `svg` in wasm | |
run: cargo build --verbose -F svg --target wasm32-unknown-unknown | |
- name: Build with `svg` in wasm-bindgen | |
run: cargo build --verbose -F svg,wasm-bindgen --target wasm32-unknown-unknown | |
# With feature `image`. Target: normal & wasm only | |
- name: Build with `image` | |
run: cargo build --verbose -F image | |
- name: Build with `image` in wasm | |
run: cargo build --verbose -F image --target wasm32-unknown-unknown | |
# With feature `wasm-bindgen`. Target: wasm only | |
- name: Build with `wasm-bindgen` | |
run: cargo build --verbose -F wasm-bindgen --target wasm32-unknown-unknown | |
# Benchmarks | |
- name: Build benchmarks | |
run: cargo build --benches | |
examples: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install wasm32-unknown-unknown target | |
run: rustup target add wasm32-unknown-unknown | |
# Examples | |
- name: Build examples | |
run: | | |
for example in examples/*.rs; do | |
cargo run --example "$(basename "${example%.rs}")" -Fsvg,image | |
cargo build --example "$(basename "${example%.rs}")" -Fsvg,image --target wasm32-unknown-unknown | |
done | |
tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
# Tests | |
- name: Run tests | |
run: cargo test --verbose -F svg,image | |
meta: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
# Typos | |
- name: typos-action | |
uses: crate-ci/[email protected] | |
- name: format | |
run: cargo fmt --all -- --check |