Skip to content

Commit 05ee865

Browse files
authored
Fix
1 parent 15734ff commit 05ee865

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tests/VeryBasicAuthTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
});
3737

3838
test('request with incorrect credentials fails - text/html', function () {
39-
$response = withHeaders([
39+
$response = withHeader([
4040
'PHP_AUTH_USER' => str_random(20),
4141
'PHP_AUTH_PW' => str_random(20),
4242
])->get('/');
@@ -48,7 +48,7 @@
4848
});
4949

5050
test('request with incorrect credentials fails - json', function () {
51-
$response = withHeaders([
51+
$response = withHeader([
5252
'PHP_AUTH_USER' => str_random(20),
5353
'PHP_AUTH_PW' => str_random(20),
5454
'Accept' => 'application/json',
@@ -66,7 +66,7 @@
6666
test('request with incorrect credentials fails - view', function () {
6767
config()->set('very_basic_auth.error_view', 'very_basic_auth::default');
6868

69-
$response = withHeaders([
69+
$response = withHeader([
7070
'PHP_AUTH_USER' => str_random(20),
7171
'PHP_AUTH_PW' => str_random(20),
7272
])->get('/');
@@ -79,7 +79,7 @@
7979
});
8080

8181
test('request with correct credentials passes', function () {
82-
$response = withHeaders([
82+
$response = withHeader([
8383
'PHP_AUTH_USER' => config('very_basic_auth.user'),
8484
'PHP_AUTH_PW' => config('very_basic_auth.password'),
8585
])->get('/');
@@ -103,7 +103,7 @@
103103
});
104104

105105
test('request with incorrect inline credentials fails', function () {
106-
$response = withHeaders([
106+
$response = withHeader([
107107
'PHP_AUTH_USER' => str_random(20),
108108
'PHP_AUTH_PW' => str_random(20),
109109
])->get('/inline');
@@ -113,7 +113,7 @@
113113
});
114114

115115
test('request with correct inline credentials passes', function () {
116-
$response = withHeaders([
116+
$response = withHeader([
117117
'PHP_AUTH_USER' => config('very_basic_auth.user'),
118118
'PHP_AUTH_PW' => config('very_basic_auth.password'),
119119
])->get('/inline');
@@ -132,7 +132,7 @@
132132
$response = get('/test');
133133

134134
expect($response->getStatusCode())->toEqual(401);
135-
expect($response->getContent())->toEqual('Custom reponse');
135+
expect($response->getContent())->toEqual('Custom response');
136136

137137
// Default response handler
138138
app()->bind(

0 commit comments

Comments
 (0)