feat(lib): remove extern Url type usage
BREAKING CHANGE: The `Url` type is no longer used. Any instance in the `Client` API has had it replaced with `hyper::Uri`. This also means `Error::Uri` has changed types to `hyper::error::UriError`. The type `hyper::header::parsing::HTTP_VALUE` has been made private, as an implementation detail. The function `http_percent_encoding` should be used instead.
This commit is contained in:
@@ -28,7 +28,7 @@ fn get_one_at_a_time(b: &mut test::Bencher) {
|
||||
|
||||
let client = hyper::Client::new(&handle);
|
||||
|
||||
let url: hyper::Url = format!("http://{}/get", addr).parse().unwrap();
|
||||
let url: hyper::Uri = format!("http://{}/get", addr).parse().unwrap();
|
||||
|
||||
b.bytes = 160 * 2 + PHRASE.len() as u64;
|
||||
b.iter(move || {
|
||||
@@ -51,7 +51,7 @@ fn post_one_at_a_time(b: &mut test::Bencher) {
|
||||
|
||||
let client = hyper::Client::new(&handle);
|
||||
|
||||
let url: hyper::Url = format!("http://{}/get", addr).parse().unwrap();
|
||||
let url: hyper::Uri = format!("http://{}/get", addr).parse().unwrap();
|
||||
|
||||
let post = "foo bar baz quux";
|
||||
b.bytes = 180 * 2 + post.len() as u64 + PHRASE.len() as u64;
|
||||
|
||||
Reference in New Issue
Block a user