use book_manager::app::App; use loco_rs::testing::prelude::*; use serial_test::serial; #[tokio::test] #[serial] async fn test_books_route_exists() { request::(|request, _ctx| async move { // Try to access books test endpoint let response = request.get("/api/books/test").await; println!("Status: {}", response.status_code()); println!("Body: {}", response.text()); // Check if we get JSON response assert_eq!(response.status_code(), 200); let body = response.text(); assert!(body.contains("Books controller is working"), "Got: {}", body); }) .await; }