From c42131cbf173981242f8ad8caa2663f8dc4f0955 Mon Sep 17 00:00:00 2001 From: Nabeel Shahzad Date: Sat, 30 Dec 2017 12:42:45 -0600 Subject: [PATCH] add a few more tests for the authorization header --- tests/ApiTest.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/ApiTest.php b/tests/ApiTest.php index 8b963501..c70a023c 100644 --- a/tests/ApiTest.php +++ b/tests/ApiTest.php @@ -34,9 +34,17 @@ class ApiTest extends TestCase ->assertStatus(200) ->assertJson(['icao' => $airport->icao], true); + $this->withHeaders(['authorization' => 'testadminapikey'])->get($uri) + ->assertStatus(200) + ->assertJson(['icao' => $airport->icao], true); + $this->withHeaders(['AUTHORIZATION' => 'testadminapikey'])->get($uri) ->assertStatus(200) ->assertJson(['icao' => $airport->icao], true); + + $this->withHeaders(['AuThOrIzAtIoN' => 'testadminapikey'])->get($uri) + ->assertStatus(200) + ->assertJson(['icao' => $airport->icao], true); } /**