fix: add X-Api-Key header to API feature tests and register auth routes

This commit is contained in:
Ovidiu U
2026-04-05 20:32:20 +01:00
parent 130576c9ba
commit 649772f65f
5 changed files with 28 additions and 0 deletions

View File

@@ -8,6 +8,10 @@ use Illuminate\Support\Facades\Http;
uses(RefreshDatabase::class);
beforeEach(function () {
$this->withHeaders(['X-Api-Key' => config('app.api_secret_key')]);
});
it('returns stations near coordinates filtered by fuel type', function () {
$station = Station::factory()->create(['lat' => 52.555064, 'lng' => -0.256119]);
StationPriceCurrent::factory()->create([