File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 26
26
interface HttpClientInterface
27
27
{
28
28
public const OPTIONS_DEFAULTS = [
29
- 'auth ' => null , // string - a username:password enabling HTTP Basic authentication
29
+ 'auth_basic ' => null , // string - a username:password enabling HTTP Basic authentication (RFC 7617)
30
+ 'auth_bearer ' => null , // string - a token enabling HTTP Bearer authorization (RFC 6750)
30
31
'query ' => [], // string[] - associative array of query string values to merge with the request's URL
31
32
'headers ' => [], // iterable|string[]|string[][] - headers names provided as keys or as part of values
32
33
'body ' => '' , // array|string|resource|\Traversable|\Closure - the callback SHOULD yield a string
Original file line number Diff line number Diff line change @@ -214,7 +214,7 @@ public function testRedirects()
214
214
{
215
215
$ client = $ this ->getHttpClient ();
216
216
$ response = $ client ->request ('POST ' , 'http://localhost:8057/301 ' , [
217
- 'auth ' => 'foo:bar ' ,
217
+ 'auth_basic ' => 'foo:bar ' ,
218
218
'body ' => function () {
219
219
yield 'foo=bar ' ;
220
220
},
@@ -291,7 +291,7 @@ public function testMaxRedirects()
291
291
$ client = $ this ->getHttpClient ();
292
292
$ response = $ client ->request ('GET ' , 'http://localhost:8057/301 ' , [
293
293
'max_redirects ' => 1 ,
294
- 'auth ' => 'foo:bar ' ,
294
+ 'auth_basic ' => 'foo:bar ' ,
295
295
]);
296
296
297
297
try {
You can’t perform that action at this time.
0 commit comments