mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 09:34:04 +00:00
Update SQL syntax in tests for MySQL 8 (#35)
* Bump MySQL to v8 in CI * Remove `identified by` from queries executed in tests
This commit is contained in:
parent
ce8e74e978
commit
fd6070ff1b
2 changed files with 4 additions and 4 deletions
|
|
@ -305,7 +305,7 @@ test('database credentials can be provided to PermissionControlledMySQLDatabaseM
|
|||
$password = Str::random('8');
|
||||
$mysql2DB = DB::connection('mysql2');
|
||||
$mysql2DB->statement("CREATE USER `{$username}`@`%` IDENTIFIED BY '{$password}';");
|
||||
$mysql2DB->statement("GRANT ALL PRIVILEGES ON *.* TO `{$username}`@`%` identified by '{$password}' WITH GRANT OPTION;");
|
||||
$mysql2DB->statement("GRANT ALL PRIVILEGES ON *.* TO `{$username}`@`%` WITH GRANT OPTION;");
|
||||
$mysql2DB->statement("FLUSH PRIVILEGES;");
|
||||
|
||||
DB::purge('mysql2'); // forget the mysql2 connection so that it uses the new credentials the next time
|
||||
|
|
@ -350,7 +350,7 @@ test('tenant database can be created by using the username and password from ten
|
|||
$password = Str::random('8');
|
||||
$mysqlDB = DB::connection('mysql');
|
||||
$mysqlDB->statement("CREATE USER `{$username}`@`%` IDENTIFIED BY '{$password}';");
|
||||
$mysqlDB->statement("GRANT ALL PRIVILEGES ON *.* TO `{$username}`@`%` identified by '{$password}' WITH GRANT OPTION;");
|
||||
$mysqlDB->statement("GRANT ALL PRIVILEGES ON *.* TO `{$username}`@`%` WITH GRANT OPTION;");
|
||||
$mysqlDB->statement("FLUSH PRIVILEGES;");
|
||||
|
||||
DB::purge('mysql2'); // forget the mysql2 connection so that it uses the new credentials the next time
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue