Skip to content

Commit

Permalink
run style.rs from ci/style.sh instead of ci/run.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
rmehri01 committed Dec 25, 2024
1 parent 955af3e commit d54c31a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions ci/style.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ if [ -n "${CI:-}" ]; then
check="--check"
fi

cargo test --manifest-path libc-test/Cargo.toml --test style

command -v rustfmt
rustfmt -V

Expand Down
7 changes: 6 additions & 1 deletion libc-test/test/style.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,12 @@ macro_rules! t {
}

#[test]
fn main() {
fn check_style() {
if env::var("LIBC_CI").is_ok() {
// we already run this in the style.sh script
return;
}

let arg = env::args().skip(1).next().unwrap_or("../src".to_string());

let mut errors = Errors { errs: false };
Expand Down

0 comments on commit d54c31a

Please sign in to comment.