hoc/tests/json.rs

17 lines
372 B
Rust
Raw Normal View History

mod util;
#[actix_rt::test]
async fn json_returns_success() {
let test_app = util::spawn_app().await;
2021-09-03 13:00:38 +02:00
let client = awc::Client::default();
let response = client
.get(&format!("{}/github/vbrandl/hoc/json", test_app.address))
.send()
.await
.expect("Failed to execute request");
assert!(response.status().is_success());
}