1
0
Fork 0
mirror of https://github.com/actix/actix-web.git synced 2024-05-20 01:08:10 +00:00

add test for duplicate dynamic segent name

This commit is contained in:
Rob Ede 2021-11-23 15:57:18 +00:00
parent bcbbc115aa
commit 9bdd334bb4
No known key found for this signature in database
GPG key ID: 97C636207D3EF933

View file

@ -1770,6 +1770,12 @@ mod tests {
match_methods_agree!(["/v{v}", "/ver/{v}"] => "", "s/v", "/v1", "/v1/xx", "/ver/i3/5", "/ver/1");
}
#[test]
#[should_panic]
fn duplicate_segment_name() {
ResourceDef::new("/user/{id}/post/{id}");
}
#[test]
#[should_panic]
fn invalid_dynamic_segment_delimiter() {