diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/unit/gfx/Cargo.toml | 2 | ||||
-rw-r--r-- | tests/unit/net/Cargo.toml | 7 | ||||
-rw-r--r-- | tests/unit/net/data_loader.rs | 5 | ||||
-rw-r--r-- | tests/unit/net/http_loader.rs | 9 | ||||
-rw-r--r-- | tests/unit/net/lib.rs | 1 | ||||
-rw-r--r-- | tests/unit/profile/Cargo.toml | 2 | ||||
-rw-r--r-- | tests/unit/script/Cargo.toml | 2 | ||||
-rw-r--r-- | tests/unit/style/Cargo.toml | 10 |
8 files changed, 23 insertions, 15 deletions
diff --git a/tests/unit/gfx/Cargo.toml b/tests/unit/gfx/Cargo.toml index 060bb09b01e..87075b177e1 100644 --- a/tests/unit/gfx/Cargo.toml +++ b/tests/unit/gfx/Cargo.toml @@ -11,5 +11,5 @@ doctest = false [dependencies] gfx = {path = "../../../components/gfx"} -ipc-channel = "0.4.0" +ipc-channel = "0.5" style = {path = "../../../components/style"} diff --git a/tests/unit/net/Cargo.toml b/tests/unit/net/Cargo.toml index 3f87e8fe429..1c9a275e445 100644 --- a/tests/unit/net/Cargo.toml +++ b/tests/unit/net/Cargo.toml @@ -10,12 +10,13 @@ path = "lib.rs" doctest = false [dependencies] -content-blocker = "0.2" +content-blocker = "0.2.1" cookie = "0.2" devtools_traits = {path = "../../../components/devtools_traits"} flate2 = "0.2.0" hyper = "0.9.9" -ipc-channel = "0.4.0" +hyper_serde = "0.1.4" +ipc-channel = "0.5" msg = {path = "../../../components/msg"} net = {path = "../../../components/net"} net_traits = {path = "../../../components/net_traits"} @@ -23,5 +24,5 @@ plugins = {path = "../../../components/plugins"} profile_traits = {path = "../../../components/profile_traits"} time = "0.1" unicase = "1.0" -url = {version = "1.0.0", features = ["heap_size"]} +url = {version = "1.2", features = ["heap_size"]} util = {path = "../../../components/util"} diff --git a/tests/unit/net/data_loader.rs b/tests/unit/net/data_loader.rs index f73331a53be..2916cb7e30c 100644 --- a/tests/unit/net/data_loader.rs +++ b/tests/unit/net/data_loader.rs @@ -3,7 +3,9 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ extern crate hyper; +extern crate hyper_serde; +use hyper_serde::Serde; use ipc_channel::ipc; use msg::constellation_msg::{PipelineId, ReferrerPolicy}; use net_traits::LoadConsumer::Channel; @@ -44,7 +46,8 @@ fn assert_parse(url: &'static str, classifier, CancellationListener::new(None)); let response = start_port.recv().unwrap(); - assert_eq!(&response.metadata.content_type, &content_type); + assert_eq!(&response.metadata.content_type.map(Serde::into_inner), + &content_type); assert_eq!(&response.metadata.charset, &charset); let progress = response.progress_port.recv().unwrap(); diff --git a/tests/unit/net/http_loader.rs b/tests/unit/net/http_loader.rs index 53f79178aab..e8e44789cf0 100644 --- a/tests/unit/net/http_loader.rs +++ b/tests/unit/net/http_loader.rs @@ -18,6 +18,7 @@ use hyper::http::RawStatus; use hyper::method::Method; use hyper::mime::{Mime, SubLevel, TopLevel}; use hyper::status::StatusCode; +use hyper_serde::Serde; use msg::constellation_msg::{PipelineId, ReferrerPolicy}; use net::cookie::Cookie; use net::cookie_storage::CookieStorage; @@ -1584,7 +1585,8 @@ fn test_auth_ui_sets_header_on_401() { }, DEFAULT_USER_AGENT.to_owned(), &CancellationListener::new(None), None) { Err(e) => panic!("response contained error {:?}", e), Ok(response) => { - assert_eq!(response.metadata.status, Some(RawStatus(200, Cow::Borrowed("Ok")))); + assert_eq!(response.metadata.status, + Some(Serde(RawStatus(200, Cow::Borrowed("Ok"))))); } } } @@ -1618,7 +1620,8 @@ fn test_auth_ui_needs_www_auth() { match response { Err(e) => panic!("response contained error {:?}", e), Ok(response) => { - assert_eq!(response.metadata.status, Some(RawStatus(401, Cow::Borrowed("Unauthorized")))); + assert_eq!(response.metadata.status, + Some(Serde(RawStatus(401, Cow::Borrowed("Unauthorized"))))); } } } @@ -1944,7 +1947,7 @@ fn load_request_for_custom_response(expected_body: Vec<u8>) -> (Metadata, String fn test_custom_response() { let expected_body = b"Yay!".to_vec(); let (metadata, body) = load_request_for_custom_response(expected_body.clone()); - assert_eq!(metadata.status, Some(RawStatus(200, Cow::Borrowed("OK")))); + assert_eq!(metadata.status, Some(Serde(RawStatus(200, Cow::Borrowed("OK"))))); assert_eq!(body, String::from_utf8(expected_body).unwrap()); } diff --git a/tests/unit/net/lib.rs b/tests/unit/net/lib.rs index 7923ede897d..1acdb9bb6ae 100644 --- a/tests/unit/net/lib.rs +++ b/tests/unit/net/lib.rs @@ -10,6 +10,7 @@ extern crate cookie as cookie_rs; extern crate devtools_traits; extern crate flate2; extern crate hyper; +extern crate hyper_serde; extern crate ipc_channel; extern crate msg; extern crate net; diff --git a/tests/unit/profile/Cargo.toml b/tests/unit/profile/Cargo.toml index 0c79370271c..515a0a2fa17 100644 --- a/tests/unit/profile/Cargo.toml +++ b/tests/unit/profile/Cargo.toml @@ -12,4 +12,4 @@ doctest = false [dependencies] profile = {path = "../../../components/profile"} profile_traits = {path = "../../../components/profile_traits"} -ipc-channel = "0.4.0" +ipc-channel = "0.5" diff --git a/tests/unit/script/Cargo.toml b/tests/unit/script/Cargo.toml index 0d784863261..4a4e0c96d6b 100644 --- a/tests/unit/script/Cargo.toml +++ b/tests/unit/script/Cargo.toml @@ -13,4 +13,4 @@ doctest = false msg = {path = "../../../components/msg"} plugins = {path = "../../../components/plugins"} script = {path = "../../../components/script"} -url = {version = "1.0.0", features = ["heap_size"]} +url = {version = "1.2", features = ["heap_size"]} diff --git a/tests/unit/style/Cargo.toml b/tests/unit/style/Cargo.toml index ee1465af0a7..3d048e4f070 100644 --- a/tests/unit/style/Cargo.toml +++ b/tests/unit/style/Cargo.toml @@ -10,13 +10,13 @@ path = "lib.rs" doctest = false [dependencies] -app_units = "0.2.5" -cssparser = {version = "0.5.4", features = ["heap_size"]} -euclid = "0.8.2" +app_units = "0.3" +cssparser = {version = "0.5.7", features = ["heap_size"]} +euclid = "0.9" rustc-serialize = "0.3" selectors = {version = "0.8", features = ["heap_size"]} -string_cache = {version = "0.2", features = ["heap_size"]} +string_cache = {version = "0.2.23", features = ["heap_size"]} style = {path = "../../../components/style"} style_traits = {path = "../../../components/style_traits"} -url = {version = "1.0.0", features = ["heap_size"]} +url = {version = "1.2", features = ["heap_size"]} util = {path = "../../../components/util"} |