mirror of
https://github.com/elyby/accounts.git
synced 2025-05-31 14:11:46 +05:30
Инициализировано Yii2 приложение, выпилены лишние части, накинуты чуточку нужных
This commit is contained in:
17
tests/codeception/common/templates/fixtures/user.php
Normal file
17
tests/codeception/common/templates/fixtures/user.php
Normal file
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
/**
|
||||
* @var $faker \Faker\Generator
|
||||
* @var $index integer
|
||||
*/
|
||||
|
||||
$security = Yii::$app->getSecurity();
|
||||
|
||||
return [
|
||||
'username' => $faker->userName,
|
||||
'email' => $faker->email,
|
||||
'auth_key' => $security->generateRandomString(),
|
||||
'password_hash' => $security->generatePasswordHash('password_' . $index),
|
||||
'password_reset_token' => $security->generateRandomString() . '_' . time(),
|
||||
'created_at' => time(),
|
||||
'updated_at' => time(),
|
||||
];
|
||||
Reference in New Issue
Block a user