OK, fine. No testing.
This commit is contained in:
parent
4e2c632485
commit
550578afde
11
.github/workflows/ci_checks.yml
vendored
11
.github/workflows/ci_checks.yml
vendored
@ -35,15 +35,6 @@ jobs:
|
||||
- run: rustup target install --toolchain=${{ matrix.rust }} thumbv6m-none-eabi
|
||||
- run: cargo build --all
|
||||
- run: cargo build --all --release
|
||||
testing:
|
||||
name: Testing
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
toolchain: stable
|
||||
- run: cargo test --lib --target=x86_64-unknown-linux-gnu
|
||||
linting:
|
||||
name: Linting
|
||||
runs-on: ubuntu-latest
|
||||
@ -59,7 +50,7 @@ jobs:
|
||||
- uses: actions-rs/clippy-check@v1
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
args: --all-targets --all-features -- -D warnings
|
||||
args: --all-features -- -D warnings
|
||||
formatting:
|
||||
name: Formatting
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
20
src/lib.rs
20
src/lib.rs
@ -1,20 +0,0 @@
|
||||
//! # Library Code for the rp2040-project-template application
|
||||
//!
|
||||
//! Code in this file can be tested on the host with `cargo
|
||||
//! test --lib --target=<your PC's target>`
|
||||
|
||||
#[cfg_attr(not(test), no_std)]
|
||||
|
||||
/// LED on-period and off-period, in milliseconds
|
||||
pub const LED_DELAY_MS: u32 = 500;
|
||||
|
||||
#[cfg(test)]
|
||||
mod test {
|
||||
#[test]
|
||||
fn it_works() {
|
||||
let sum = 2 + 2;
|
||||
assert_eq!(4, sum);
|
||||
}
|
||||
}
|
||||
|
||||
// End of file
|
||||
@ -59,10 +59,10 @@ fn main() -> ! {
|
||||
loop {
|
||||
info!("on!");
|
||||
led_pin.set_high().unwrap();
|
||||
delay.delay_ms(rp2040_project_template::LED_DELAY_MS);
|
||||
delay.delay_ms(500);
|
||||
info!("off!");
|
||||
led_pin.set_low().unwrap();
|
||||
delay.delay_ms(rp2040_project_template::LED_DELAY_MS);
|
||||
delay.delay_ms(500);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user