mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 22:44:05 +00:00
fixed TestSeeder class not resolved
This commit is contained in:
parent
680a2b6be1
commit
0692cdc36a
2 changed files with 24 additions and 17 deletions
|
|
@ -14,6 +14,7 @@ use Stancl\Tenancy\Jobs\SeedDatabase;
|
||||||
use Stancl\Tenancy\TenantDatabaseManagers\MySQLDatabaseManager;
|
use Stancl\Tenancy\TenantDatabaseManagers\MySQLDatabaseManager;
|
||||||
use Stancl\Tenancy\Tests\Etc\Tenant;
|
use Stancl\Tenancy\Tests\Etc\Tenant;
|
||||||
use Illuminate\Foundation\Auth\User as Authenticable;
|
use Illuminate\Foundation\Auth\User as Authenticable;
|
||||||
|
use Stancl\Tenancy\Tests\Etc\TestSeeder;
|
||||||
|
|
||||||
uses(Stancl\Tenancy\Tests\TestCase::class);
|
uses(Stancl\Tenancy\Tests\TestCase::class);
|
||||||
|
|
||||||
|
|
@ -93,23 +94,6 @@ class User extends Authenticable
|
||||||
protected $guarded = [];
|
protected $guarded = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
class TestSeeder extends Seeder
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Run the database seeds.
|
|
||||||
*
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
public function run()
|
|
||||||
{
|
|
||||||
DB::table('users')->insert([
|
|
||||||
'name' => 'Seeded User',
|
|
||||||
'email' => 'seeded@user',
|
|
||||||
'password' => bcrypt('password'),
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
class CreateSuperuser
|
class CreateSuperuser
|
||||||
{
|
{
|
||||||
protected $tenant;
|
protected $tenant;
|
||||||
|
|
|
||||||
23
tests/Etc/TestSeeder.php
Normal file
23
tests/Etc/TestSeeder.php
Normal file
|
|
@ -0,0 +1,23 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Stancl\Tenancy\Tests\Etc;
|
||||||
|
|
||||||
|
use Illuminate\Database\Seeder;
|
||||||
|
use Illuminate\Support\Facades\DB;
|
||||||
|
|
||||||
|
class TestSeeder extends Seeder
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Run the database seeds.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
public function run()
|
||||||
|
{
|
||||||
|
DB::table('users')->insert([
|
||||||
|
'name' => 'Seeded User',
|
||||||
|
'email' => 'seeded@user',
|
||||||
|
'password' => bcrypt('password'),
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue