feat: have test unswer code
This commit is contained in:
parent
1019752215
commit
f282f126a6
|
@ -131,6 +131,7 @@ async fn main() -> std::io::Result<()> {
|
|||
.wrap(Logger::default())
|
||||
.app_data(web::Data::new(state.clone()))
|
||||
.route("/", web::post().to(connect_handler))
|
||||
.route("/test", web::post().to(test_handler))
|
||||
})
|
||||
.bind("0.0.0.0:8080")?
|
||||
.run()
|
||||
|
|
3
src/test.rs
Normal file
3
src/test.rs
Normal file
|
@ -0,0 +1,3 @@
|
|||
async fn test_handler() -> Result<HttpResponse, actix_web::Error> {
|
||||
Ok(HttpResponse::Ok().body("Hello, World!"))
|
||||
}
|
Loading…
Reference in New Issue
Block a user