Adjust test, make it extra-clear when we're missing something
This commit is contained in:
Родитель
38572945ac
Коммит
479d9972c9
|
@ -207,7 +207,11 @@ impl From<CAChannelLabel> for mixer::Channel {
|
|||
sys::kAudioChannelLabel_TopBackCenter => mixer::Channel::TopBackCenter,
|
||||
sys::kAudioChannelLabel_TopBackRight => mixer::Channel::TopBackRight,
|
||||
sys::kAudioChannelLabel_Unknown => mixer::Channel::Discrete,
|
||||
_ => panic!("Label not handled"),
|
||||
sys::kAudioChannelLabel_Unused => mixer::Channel::Silence,
|
||||
v => {
|
||||
eprintln!("Warning: channel label value {} isn't handled", v);
|
||||
mixer::Channel::Silence
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -376,7 +376,6 @@ fn test_get_default_device_id_with_inout_type() {
|
|||
#[test]
|
||||
fn test_convert_channel_layout() {
|
||||
let pairs = [
|
||||
(vec![kAudioObjectUnknown], vec![mixer::Channel::Silence]),
|
||||
(
|
||||
vec![kAudioChannelLabel_Mono],
|
||||
vec![mixer::Channel::FrontCenter],
|
||||
|
@ -398,7 +397,7 @@ fn test_convert_channel_layout() {
|
|||
vec![
|
||||
mixer::Channel::FrontLeft,
|
||||
mixer::Channel::FrontRight,
|
||||
mixer::Channel::Silence,
|
||||
mixer::Channel::Discrete,
|
||||
],
|
||||
),
|
||||
(
|
||||
|
|
Загрузка…
Ссылка в новой задаче