mirror of https://github.com/fafhrd91/actix-web
Added comment for test_client.rs, updated spacing in test function
This commit is contained in:
parent
b4ed682b77
commit
69e396ab6a
|
@ -511,10 +511,10 @@ fn client_read_until_eof() {
|
|||
fn client_basic_auth() {
|
||||
let mut srv =
|
||||
test::TestServer::new(|app| app.handler(|_| HttpResponse::Ok().body(STR)));
|
||||
|
||||
/// set authorization header to Basic <base64 encoded username:password>
|
||||
let request = srv
|
||||
.get()
|
||||
.basic_auth("username",Some("password"))
|
||||
.basic_auth("username", Some("password"))
|
||||
.finish()
|
||||
.unwrap();
|
||||
let repr = format!("{:?}", request);
|
||||
|
@ -525,7 +525,7 @@ fn client_basic_auth() {
|
|||
fn client_bearer_auth() {
|
||||
let mut srv =
|
||||
test::TestServer::new(|app| app.handler(|_| HttpResponse::Ok().body(STR)));
|
||||
|
||||
/// set authorization header to Bearer <token>
|
||||
let request = srv
|
||||
.get()
|
||||
.bearer_auth("someS3cr3tAutht0k3n")
|
||||
|
|
Loading…
Reference in New Issue