Merge branch 'audio-video-format-tests' into 'main'

video: Remove nonsensical test

See merge request gstreamer/gstreamer-rs!1432
This commit is contained in:
Sebastian Dröge 2024-04-27 16:13:50 +00:00
commit b61b641096
2 changed files with 4 additions and 9 deletions

View file

@ -364,7 +364,8 @@ mod tests {
fn test_display() {
gst::init().unwrap();
format!("{}", crate::AudioFormat::S16be);
assert_eq!(format!("{}", crate::AudioFormat::S16be), "S16BE");
assert_eq!(format!("{:?}", crate::AudioFormat::S16be), "S16be");
}
#[test]

View file

@ -480,18 +480,12 @@ mod tests {
);
}
#[test]
#[should_panic(expected = "gst_video_format_to_string returned NULL")]
fn enum_to_string_panics() {
assert_eq!(&format!("{}", crate::VideoFormat::__Unknown(-1)), "UNKNOWN");
assert_eq!(crate::VideoFormat::__Unknown(-1).to_str(), "UNKNOWN");
}
#[test]
fn test_display() {
gst::init().unwrap();
format!("{}", crate::VideoFormat::Nv16);
assert_eq!(format!("{}", crate::VideoFormat::Nv16), "NV16");
assert_eq!(format!("{:?}", crate::VideoFormat::Nv16), "Nv16");
}
#[test]