mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-02 14:36:17 +00:00
#591 - tests
This commit is contained in:
@ -5,6 +5,7 @@
|
||||
use App\Models\SourceControl;
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
use Illuminate\Support\Facades\Http;
|
||||
use PHPUnit\Framework\Attributes\DataProvider;
|
||||
use Tests\TestCase;
|
||||
|
||||
class SourceControlsTest extends TestCase
|
||||
@ -13,9 +14,8 @@ class SourceControlsTest extends TestCase
|
||||
|
||||
/**
|
||||
* @param array<string, mixed> $input
|
||||
*
|
||||
* @dataProvider data
|
||||
*/
|
||||
#[DataProvider('data')]
|
||||
public function test_connect_provider(string $provider, ?string $customUrl, array $input): void
|
||||
{
|
||||
$this->actingAs($this->user);
|
||||
@ -53,9 +53,7 @@ public function test_connect_provider(string $provider, ?string $customUrl, arra
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider data
|
||||
*/
|
||||
#[DataProvider('data')]
|
||||
public function test_delete_provider(string $provider): void
|
||||
{
|
||||
$this->actingAs($this->user);
|
||||
@ -75,9 +73,7 @@ public function test_delete_provider(string $provider): void
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider data
|
||||
*/
|
||||
#[DataProvider('data')]
|
||||
public function test_cannot_delete_provider(string $provider): void
|
||||
{
|
||||
$this->actingAs($this->user);
|
||||
@ -104,9 +100,8 @@ public function test_cannot_delete_provider(string $provider): void
|
||||
|
||||
/**
|
||||
* @param array<string, mixed> $input
|
||||
*
|
||||
* @dataProvider data
|
||||
*/
|
||||
#[DataProvider('data')]
|
||||
public function test_edit_source_control(string $provider, ?string $url, array $input): void
|
||||
{
|
||||
Http::fake();
|
||||
|
Reference in New Issue
Block a user