**Add public API documentation access and navigation links**

- 📚 Added "API Dokumentation" link to the sidebar and header navigation.
- 🔓 Defined `viewApiDocs` gate for public access to API documentation.
-  Added feature tests for API documentation route accessibility and OpenAPI document serving.
This commit is contained in:
HolgerHatGarKeineNode
2026-06-08 01:34:00 +02:00
parent d1b7352fca
commit 7510946f38
4 changed files with 27 additions and 4 deletions
+15
View File
@@ -0,0 +1,15 @@
<?php
use Illuminate\Support\Facades\Gate;
it('exposes the api docs route publicly', function () {
expect(Gate::forUser(null)->allows('viewApiDocs'))->toBeTrue();
});
it('allows guests to open the api documentation', function () {
$this->get(route('scramble.docs.ui'))->assertSuccessful();
});
it('serves the openapi document to guests', function () {
$this->get(route('scramble.docs.document'))->assertSuccessful();
});