mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-08-03 09:44:41 +02:00
Fixed code style.
This commit is contained in:
parent
1aed1d1d26
commit
9a7223a301
142 changed files with 534 additions and 716 deletions
|
@ -39,7 +39,7 @@ class StructuralDBElementTest extends TestCase
|
|||
protected $child1_1;
|
||||
protected $child1_2;
|
||||
|
||||
public function setUp() : void
|
||||
public function setUp(): void
|
||||
{
|
||||
parent::setUp(); // TODO: Change the autogenerated stub
|
||||
|
||||
|
|
|
@ -27,7 +27,6 @@ use PHPUnit\Framework\TestCase;
|
|||
|
||||
class PermissionsEmbedTest extends TestCase
|
||||
{
|
||||
|
||||
public function testGetPermissionValue()
|
||||
{
|
||||
$embed = new PermissionsEmbed();
|
||||
|
|
|
@ -38,12 +38,12 @@ class UserTest extends TestCase
|
|||
$this->assertEquals('John Doe (username)', $user->getFullName(true));
|
||||
}
|
||||
|
||||
public function googleAuthenticatorEnabledDataProvider() : array
|
||||
public function googleAuthenticatorEnabledDataProvider(): array
|
||||
{
|
||||
return [
|
||||
[null, false],
|
||||
['', false],
|
||||
['SSSk38498', true]
|
||||
['SSSk38498', true],
|
||||
];
|
||||
}
|
||||
|
||||
|
@ -54,7 +54,7 @@ class UserTest extends TestCase
|
|||
{
|
||||
$user = new User();
|
||||
$user->setGoogleAuthenticatorSecret($secret);
|
||||
$this->assertSame($expected ,$user->isGoogleAuthenticatorEnabled());
|
||||
$this->assertSame($expected, $user->isGoogleAuthenticatorEnabled());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -63,7 +63,7 @@ class UserTest extends TestCase
|
|||
public function testSetBackupCodes()
|
||||
{
|
||||
$user = new User();
|
||||
$codes = ["test", "invalid", "test"];
|
||||
$codes = ['test', 'invalid', 'test'];
|
||||
$user->setBackupCodes($codes);
|
||||
// Backup Codes generation date must be changed!
|
||||
$this->assertEqualsWithDelta(new \DateTime(), $user->getBackupCodesGenerationDate(), 0.1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue