mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-09 23:24:06 -08:00
Fixed company unit test
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
b0d2fc787a
commit
390e8a6cc3
|
@ -16,18 +16,17 @@ class UserFactory extends Factory
|
|||
{
|
||||
return [
|
||||
'activated' => 1,
|
||||
'address' => $this->faker->address,
|
||||
'city' => $this->faker->city,
|
||||
'address' => $this->faker->address(),
|
||||
'city' => $this->faker->city(),
|
||||
'company_id' => rand(1, 4),
|
||||
'country' => $this->faker->country,
|
||||
'country' => $this->faker->country(),
|
||||
'department_id' => rand(1, 6),
|
||||
'email' => $this->faker->safeEmail,
|
||||
'employee_num' => $this->faker->numberBetween(3500, 35050),
|
||||
'first_name' => $this->faker->firstName,
|
||||
'jobtitle' => $this->faker->jobTitle,
|
||||
'last_name' => $this->faker->lastName,
|
||||
'locale' => $this->faker->locale,
|
||||
'location_id' => rand(1, 5),
|
||||
'first_name' => $this->faker->firstName(),
|
||||
'jobtitle' => $this->faker->jobTitle(),
|
||||
'last_name' => $this->faker->lastName(),
|
||||
'locale' => $this->faker->locale(),
|
||||
'notes' => 'Created by DB seeder',
|
||||
'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password
|
||||
'permissions' => '{"user":"0"}',
|
||||
|
|
|
@ -22,10 +22,10 @@ class CompanyTest extends BaseTest
|
|||
public function testACompanyCanHaveUsers()
|
||||
{
|
||||
$company = Company::factory()->create();
|
||||
User::factory()
|
||||
$user = User::factory()
|
||||
->create(
|
||||
[
|
||||
'company_id'=>$company->id
|
||||
'company_id'=> $company->id
|
||||
]
|
||||
);
|
||||
|
||||
|
|
Loading…
Reference in a new issue