Skip to content

Commit

Permalink
Merge pull request #14 from tweedegolf/ci
Browse files Browse the repository at this point in the history
Add CI
  • Loading branch information
diondokter authored Dec 21, 2023
2 parents 2995169 + 714ae92 commit 603f541
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 2 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Check project

on:
push:
branches:
- master
# Run on any PR
pull_request:

jobs:
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- run: cargo fmt --all -- --check

test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- run: cargo test

clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- run: cargo clippy -- -D warnings

4 changes: 2 additions & 2 deletions src/map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
//!
//! #[derive(Debug)]
//! enum Error {
//! // We have no errors in this test
//! BufferTooSmall
//! }
//!
//! // Initialize the flash. This can be internal or external
Expand Down Expand Up @@ -446,7 +446,7 @@ pub trait StorageItem {

/// Serialize the key-value item into the given buffer.
/// Returns the number of bytes the buffer was filled with or an error.
///
///
/// The serialized data does not have to self-describe its length or do framing.
/// This crate already stores the length of any item in flash.
fn serialize_into(&self, buffer: &mut [u8]) -> Result<usize, Self::Error>;
Expand Down

0 comments on commit 603f541

Please sign in to comment.