mirror of https://github.com/fafhrd91/actix-web
tests for multiple path failure
This commit is contained in:
parent
314ffd71c9
commit
b91607bfb2
|
@ -27,4 +27,11 @@ async fn five() -> String {
|
|||
"Hello World!".to_owned()
|
||||
}
|
||||
|
||||
const SIX: &str = "/six";
|
||||
|
||||
#[get("/six", path="SIX")]
|
||||
async fn six() -> String {
|
||||
"Hello World!".to_owned()
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
|
|
|
@ -27,3 +27,9 @@ error: HTTP method forbidden here. To handle multiple methods, use `route` inste
|
|||
|
|
||||
25 | #[delete("/five", method="GET")]
|
||||
| ^^^^^^^^^^^^
|
||||
|
||||
error: Multiple paths specified! Should be only one!
|
||||
--> $DIR/simple-fail.rs:32:20
|
||||
|
|
||||
32 | #[get("/six", path="SIX")]
|
||||
| ^^^^^
|
||||
|
|
Loading…
Reference in New Issue