mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 18:04:03 +00:00
Change @test annotations to #[Test] attributes
This commit is contained in:
parent
f9f28c9d26
commit
5fa5c3b7dd
29 changed files with 179 additions and 165 deletions
|
|
@ -5,13 +5,14 @@ declare(strict_types=1);
|
|||
namespace Stancl\Tenancy\Tests\Features;
|
||||
|
||||
use Illuminate\Support\Facades\Route;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Stancl\Tenancy\Features\CrossDomainRedirect;
|
||||
use Stancl\Tenancy\Tests\Etc\Tenant;
|
||||
use Stancl\Tenancy\Tests\TestCase;
|
||||
|
||||
class RedirectTest extends TestCase
|
||||
{
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function tenant_redirect_macro_replaces_only_the_hostname()
|
||||
{
|
||||
config([
|
||||
|
|
@ -33,7 +34,7 @@ class RedirectTest extends TestCase
|
|||
->assertRedirect('http://abcd/foobar');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function tenant_route_helper_generates_correct_url()
|
||||
{
|
||||
Route::get('/abcdef/{a?}/{b?}', function () {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ declare(strict_types=1);
|
|||
namespace Stancl\Tenancy\Tests\Features;
|
||||
|
||||
use Illuminate\Support\Facades\Event;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Stancl\Tenancy\Events\TenancyEnded;
|
||||
use Stancl\Tenancy\Events\TenancyInitialized;
|
||||
use Stancl\Tenancy\Features\TenantConfig;
|
||||
|
|
@ -22,7 +23,7 @@ class TenantConfigTest extends TestCase
|
|||
parent::tearDown();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function nested_tenant_values_are_merged()
|
||||
{
|
||||
$this->assertSame(null, config('whitelabel.theme'));
|
||||
|
|
@ -46,7 +47,7 @@ class TenantConfigTest extends TestCase
|
|||
tenancy()->end();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function config_is_merged_and_removed()
|
||||
{
|
||||
$this->assertSame(null, config('services.paypal'));
|
||||
|
|
@ -77,7 +78,7 @@ class TenantConfigTest extends TestCase
|
|||
], config('services.paypal'));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function the_value_can_be_set_to_multiple_config_keys()
|
||||
{
|
||||
$this->assertSame(null, config('services.paypal'));
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Stancl\Tenancy\Features\ViteBundler;
|
||||
use Stancl\Tenancy\Tests\Etc\Tenant;
|
||||
use Stancl\Tenancy\Tests\TestCase;
|
||||
|
|
@ -9,7 +10,7 @@ use Stancl\Tenancy\Vite as StanclVite;
|
|||
|
||||
class ViteBundlerTest extends TestCase
|
||||
{
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function the_vite_helper_uses_our_custom_class()
|
||||
{
|
||||
$vite = app(\Illuminate\Foundation\Vite::class);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue