Attribute Macro actix_web::test

source ·
#[test]
Available on crate feature macros only.
Expand description

Marks async test functions to use the actix system entry-point.

Examples

#[actix_web::test]
async fn test() {
    assert_eq!(async { "Hello world" }.await, "Hello world");
}