Skip to content

Commit

Permalink
Merge pull request #16 from obsoleszenz/fix_ci
Browse files Browse the repository at this point in the history
Actually fix ci
  • Loading branch information
Billy Messenger authored May 24, 2022
2 parents 63c1a10 + c3eaa0e commit 578bb14
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 10 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ on:
- staging
- trying

env:
RUSTFLAGS: -Dwarnings

jobs:
build_and_test:
name: Build and test
Expand All @@ -30,7 +27,7 @@ jobs:
- uses: actions/checkout@master

- name: Install alsa
run: sudo apt install alsa alsa-lib
run: sudo apt install alsa libasound2-dev

- name: Install ${{ matrix.rust }}
uses: actions-rs/toolchain@v1
Expand All @@ -45,10 +42,10 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: check
args: --all --bins --examples --tests --features decode-all
args: -p creek-core -p creek-decode-symphonia -p creek-encode-wav --tests --features decode-all

- name: tests
uses: actions-rs/cargo@v1
with:
command: test
args: --all
args: -p creek-core -p creek-decode-symphonia -p creek-encode-wav
7 changes: 3 additions & 4 deletions decode_symphonia/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,6 @@ mod tests {


let (mut decoder, file_info) = decoder.unwrap();
println!("{:?}", file_info.num_frames);

let mut data_block = DataBlock::new(1, block_size);
unsafe {
Expand All @@ -400,7 +399,7 @@ mod tests {

let first_frame = [
0.0,
0.046873,
0.046875,
0.09375,
0.1484375,
0.1953125,
Expand Down Expand Up @@ -435,7 +434,7 @@ mod tests {

let samples = &mut data_block.block[0];
for i in 0..samples.len() {
assert!(approx_eq!(f32, second_frame[i], samples[i], ulps = 2));
assert_approx_eq!(f32, second_frame[i], samples[i], ulps = 2);
}

let last_frame = [
Expand All @@ -459,7 +458,7 @@ mod tests {
}
let samples = &mut data_block.block[0];
for i in 0..samples.len() {
assert!(approx_eq!(f32, last_frame[i], samples[i], ulps = 2));
assert_approx_eq!(f32, last_frame[i], samples[i], ulps = 2);
}

assert_eq!(decoder.current_frame, file_info.num_frames - 1);
Expand Down

0 comments on commit 578bb14

Please sign in to comment.