✅ Define la estructura para tests y ejemplos
This commit is contained in:
parent
cd76355430
commit
0af85c4d77
14 changed files with 74 additions and 24 deletions
15
tests/src/server/health_check.rs
Normal file
15
tests/src/server/health_check.rs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
use pagetop::prelude::*;
|
||||
|
||||
struct HealthCheck;
|
||||
|
||||
impl ModuleTrait for HealthCheck {}
|
||||
|
||||
async fn spawn_app() {
|
||||
let server = Application::prepare(&HealthCheck).unwrap().server();
|
||||
let _ = actix_web::rt::spawn(server);
|
||||
}
|
||||
|
||||
#[actix_web::test]
|
||||
async fn health_check_works() {
|
||||
spawn_app();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue