Skip to content

Commit

Permalink
Fix CI rustfmt job (#841)
Browse files Browse the repository at this point in the history
* fix CI rustfmt job

* apply nightly rustfmt

* re-apply nightly rustftm
  • Loading branch information
Robbepop authored Dec 8, 2023
1 parent bed9ae4 commit eac84fe
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 18 deletions.
11 changes: 3 additions & 8 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,16 +109,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- uses: actions-rs/toolchain@v1
- uses: dtolnay/rust-toolchain@nightly
with:
profile: minimal
toolchain: nightly
override: true
components: rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: Foramtting
run: cargo fmt --all -- --check

doc:
name: Documentation
Expand Down
24 changes: 14 additions & 10 deletions crates/wasmi/tests/spec/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,23 @@ pub fn run_wasm_spec_test(name: &str, config: Config) {
lexer.allow_confusing_unicode(true);
let parse_buffer = match ParseBuffer::new_with_lexer(lexer) {
Ok(buffer) => buffer,
Err(error) => panic!(
"failed to create ParseBuffer for {}: {}",
test.path(),
error
),
Err(error) => {
panic!(
"failed to create ParseBuffer for {}: {}",
test.path(),
error
)
}
};
let wast = match wast::parser::parse(&parse_buffer) {
Ok(wast) => wast,
Err(error) => panic!(
"failed to parse `.wast` spec test file for {}: {}",
test.path(),
error
),
Err(error) => {
panic!(
"failed to parse `.wast` spec test file for {}: {}",
test.path(),
error
)
}
};

execute_directives(wast, &mut context).unwrap_or_else(|error| {
Expand Down

0 comments on commit eac84fe

Please sign in to comment.