Skip to content

Commit

Permalink
1. Add CI
Browse files Browse the repository at this point in the history
  • Loading branch information
denisandroid committed May 7, 2024
1 parent daf2355 commit a3d9225
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
34 changes: 34 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

env:
CARGO_TERM_COLOR: always

jobs:
cargo-test:
strategy:
matrix:
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

steps:
- uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- uses: actions/checkout@v3
- name: Run cargo deftest
run: cargo test --verbose
- name: Run cargo alltest
run: cargo test --all-features --verbose
2 changes: 1 addition & 1 deletion examples/arr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ use core::ffi::CStr;

fn main() {
let cstr = cstr!(b"Test Custom cstr");

assert_eq!(cstr.to_bytes_with_nul(), b"Test Custom cstr\0");
}

0 comments on commit a3d9225

Please sign in to comment.