Skip to content

Commit

Permalink
refactor: call health check endpoint "ok"
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonribble committed Oct 17, 2024
1 parent e39f55c commit 7bc463b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ mod tests {
use reqwest;

#[tokio::test]
async fn test_hello_endpoint() {
let url = "http://localhost:8080/hello";
async fn test_ok_endpoint() {
let url = "http://localhost:8080/ok";
let response = reqwest::get(url).await.expect("Failed to send request");

assert_eq!(response.status(), 200);

let body = response.text().await.expect("Failed to get response text");
assert_eq!(body, "Hello, World!");
assert_eq!(body, "ok");
}
}

0 comments on commit 7bc463b

Please sign in to comment.