mirror of https://github.com/rwf2/Rocket.git
Test methods via route attribute.
This commit is contained in:
parent
2de006d9f9
commit
366eb5d158
|
@ -3,26 +3,26 @@
|
|||
|
||||
extern crate rocket;
|
||||
|
||||
#[get("/")]
|
||||
fn get() { }
|
||||
#[get("/")] fn get() { }
|
||||
#[route(GET, "/")] fn get_r() { }
|
||||
|
||||
#[put("/")]
|
||||
fn put() { }
|
||||
#[put("/")] fn put() { }
|
||||
#[route(PUT, "/")] fn put_r() { }
|
||||
|
||||
#[post("/")]
|
||||
fn post() { }
|
||||
#[post("/")] fn post() { }
|
||||
#[route(POST, "/")] fn post_r() { }
|
||||
|
||||
#[delete("/")]
|
||||
fn delete() { }
|
||||
#[delete("/")] fn delete() { }
|
||||
#[route(DELETE, "/")] fn delete_r() { }
|
||||
|
||||
#[head("/")]
|
||||
fn head() { }
|
||||
#[head("/")] fn head() { }
|
||||
#[route(HEAD, "/")] fn head_r() { }
|
||||
|
||||
#[patch("/")]
|
||||
fn patch() { }
|
||||
#[patch("/")] fn patch() { }
|
||||
#[route(PATCH, "/")] fn patch_r() { }
|
||||
|
||||
// TODO: Allow this once Diesel incompatibility is fixed.
|
||||
// #[options("/")]
|
||||
// fn options() { }
|
||||
// #[options("/")] fn options() { }
|
||||
#[route(OPTIONS, "/")] fn options_r() { }
|
||||
|
||||
fn main() { }
|
||||
|
|
Loading…
Reference in New Issue