mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-05 18:23:48 +00:00
test folder refactoring
This commit is contained in:
@@ -12,29 +12,8 @@ use Notification;
|
||||
use Storage;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AuthTest extends TestCase
|
||||
class SignFlowTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function it_generate_and_store_user()
|
||||
{
|
||||
$user = User::factory(User::class)
|
||||
->create(['role' => 'user']);
|
||||
|
||||
$this->assertDatabaseHas('users', [
|
||||
'id' => $user->id,
|
||||
'role' => 'user',
|
||||
]);
|
||||
|
||||
$this->assertDatabaseHas('user_settings', [
|
||||
'user_id' => $user->id,
|
||||
]);
|
||||
|
||||
Storage::disk('local')
|
||||
->assertExists('files/' . User::first()->id);
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
@@ -16,7 +16,28 @@ class UserAccountTest extends TestCase
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->setup = app()->make(SetupService::class);
|
||||
$this->setup = resolve(SetupService::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function it_generate_and_store_user()
|
||||
{
|
||||
$user = User::factory(User::class)
|
||||
->create(['role' => 'user']);
|
||||
|
||||
$this->assertDatabaseHas('users', [
|
||||
'id' => $user->id,
|
||||
'role' => 'user',
|
||||
]);
|
||||
|
||||
$this->assertDatabaseHas('user_settings', [
|
||||
'user_id' => $user->id,
|
||||
]);
|
||||
|
||||
Storage::disk('local')
|
||||
->assertExists('files/' . User::first()->id);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -13,7 +13,7 @@ use Mail;
|
||||
use ScssPhp\ScssPhp\Compiler;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AppTest extends TestCase
|
||||
class HomepageTest extends TestCase
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
@@ -9,7 +9,7 @@ use App\Services\SetupService;
|
||||
use Laravel\Sanctum\Sanctum;
|
||||
use Tests\TestCase;
|
||||
|
||||
class LanguageEditorTest extends TestCase
|
||||
class LanguagesTest extends TestCase
|
||||
{
|
||||
protected $setup;
|
||||
|
||||
Reference in New Issue
Block a user