()
| 314 | |
| 315 | #[test] |
| 316 | fn test_decode_resamples() { |
| 317 | // 48kHz file loaded at 24kHz target should halve the sample count |
| 318 | let samples: Vec<f32> = (0..4800).map(|i| (i as f32 / 4800.0).sin()).collect(); |
| 319 | let wav = encode_wav_bytes(&samples, 48000); |
| 320 | let decoded = decode_wav_mono(&wav, 24000).unwrap(); |
| 321 | assert_eq!(decoded.len(), 2400); |
| 322 | } |
| 323 | |
| 324 | #[test] |
| 325 | fn test_decode_upsample() { |
nothing calls this directly
no test coverage detected