Update testing.blade.md

How to force (sub)domain identification while testing
This commit is contained in:
SuperDJ 2024-10-14 09:54:19 +02:00 committed by GitHub
parent 6184708cf0
commit 98365debde
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -57,6 +57,9 @@ class TestCase // extends ...
$tenant = Tenant::create(); $tenant = Tenant::create();
tenancy()->initialize($tenant); tenancy()->initialize($tenant);
// Depending on the tenant identification middleware you may want to force the URL. For example:
URL::forceRootUrl( 'https://'.$this->tenant->domains[ 0 ]->domain.'.'.centralDomains()[ 0 ] );
} }
// ... // ...