add unit tests for converting backend input events into Input
#300
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: CI | |
on: [push, pull_request] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
unit-test: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
fail-fast: true | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo test --features=search,termwiz,termion,arbitrary | |
if: ${{ matrix.os != 'windows-latest' }} | |
- run: cargo test --features=search,termwiz,arbitrary | |
if: ${{ matrix.os == 'windows-latest' }} | |
- run: cargo test --no-default-features --features=tuirs-crossterm,search -- --skip .rs | |
- run: cargo test --no-default-features --features=tuirs-termion,search -- --skip .rs | |
if: ${{ matrix.os != 'windows-latest' }} | |
- run: cargo test --no-default-features --features=no-backend,search -- --skip .rs | |
- run: cargo test --no-default-features --features=tuirs-no-backend,search -- --skip .rs | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
with: | |
components: clippy,rustfmt | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo fmt -- --check | |
- run: cargo clippy --examples --tests -- -D warnings | |
- run: cargo clippy --examples --tests --features search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features termion -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features termion,search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features termwiz -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features termwiz,search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features no-backend -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features no-backend,search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-crossterm -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-crossterm,search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-termion -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-termion,search -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-no-backend -- -D warnings | |
- run: cargo clippy --examples --tests --no-default-features --features tuirs-no-backend,search -- -D warnings | |
- run: cargo rustdoc --features=search,termwiz,termion -p tui-textarea -- -D warnings |