diff --git a/.travis.yml b/.travis.yml index 5824e2f83..97d396d29 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,8 @@ script: - rustc --version - cargo build --all - cargo test --all - - cd examples && cargo build --features=gst-player + - cargo build --all --all-features + - cargo test --all --all-features before_install: - curl -L https://people.freedesktop.org/~slomo/gstreamer.tar.gz | tar xz diff --git a/gstreamer-audio/Cargo.toml b/gstreamer-audio/Cargo.toml index 4499c79d3..44ccd8fc7 100644 --- a/gstreamer-audio/Cargo.toml +++ b/gstreamer-audio/Cargo.toml @@ -26,8 +26,8 @@ version = "0.1" optional = true [features] -v1_10 = ["gstreamer-sys/v1_10"] -v1_12 = ["gstreamer-sys/v1_12", "v1_10"] +v1_10 = ["gstreamer-sys/v1_10", "gstreamer-audio-sys/v1_10"] +v1_12 = ["gstreamer-sys/v1_12", "gstreamer-audio-sys/v1_12", "v1_10"] embed-lgpl-docs = ["rustdoc-stripper"] purge-lgpl-docs = ["rustdoc-stripper"] default-features = [] diff --git a/gstreamer-video/Cargo.toml b/gstreamer-video/Cargo.toml index fd3a642c5..1992aca09 100644 --- a/gstreamer-video/Cargo.toml +++ b/gstreamer-video/Cargo.toml @@ -25,8 +25,8 @@ version = "0.1" optional = true [features] -v1_10 = ["gstreamer-sys/v1_10"] -v1_12 = ["gstreamer-sys/v1_12", "v1_10"] +v1_10 = ["gstreamer-sys/v1_10", "gstreamer-video-sys/v1_10"] +v1_12 = ["gstreamer-sys/v1_12", "gstreamer-video-sys/v1_12", "v1_10"] embed-lgpl-docs = ["rustdoc-stripper"] purge-lgpl-docs = ["rustdoc-stripper"] default-features = [] diff --git a/gstreamer-video/src/video_info.rs b/gstreamer-video/src/video_info.rs index dbadb2d61..d7202ec24 100644 --- a/gstreamer-video/src/video_info.rs +++ b/gstreamer-video/src/video_info.rs @@ -664,7 +664,7 @@ impl ::VideoFieldOrder { unsafe { from_glib_full(ffi::gst_video_field_order_to_string(self.to_glib())) } } - pub fn from_string(s: &str) -> Option { + pub fn from_string(s: &str) -> Self { unsafe { from_glib(ffi::gst_video_field_order_from_string(s.to_glib_none().0)) } } } @@ -674,7 +674,7 @@ impl str::FromStr for ::VideoFieldOrder { type Err = (); fn from_str(s: &str) -> Result { - Self::from_string(s).ok_or(()) + Ok(Self::from_string(s)) } }