diff options
Diffstat (limited to '')
-rw-r--r-- | tests/serve_request.rs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/serve_request.rs b/tests/serve_request.rs index 9c30bb8..5761a65 100644 --- a/tests/serve_request.rs +++ b/tests/serve_request.rs @@ -41,7 +41,8 @@ fn serves_requests_with_non_default_port(tmpdir: TempDir, port: u16) -> Result<( sleep(Duration::from_secs(1)); - let body = reqwest::blocking::get(format!("http://localhost:{}", port).as_str())?.error_for_status()?; + let body = reqwest::blocking::get(format!("http://localhost:{}", port).as_str())? + .error_for_status()?; let parsed = Document::from_read(body)?; for &file in FILES { assert!(parsed.find(|x: &Node| x.text() == file).next().is_some()); @@ -51,8 +52,9 @@ fn serves_requests_with_non_default_port(tmpdir: TempDir, port: u16) -> Result<( .find(|x: &Node| x.text() == directory) .next() .is_some()); - let dir_body = reqwest::blocking::get(format!("http://localhost:{}/{}", port, directory).as_str())? - .error_for_status()?; + let dir_body = + reqwest::blocking::get(format!("http://localhost:{}/{}", port, directory).as_str())? + .error_for_status()?; let dir_body_parsed = Document::from_read(dir_body)?; for &file in FILES { assert!(dir_body_parsed |