Use more standardized phpcs
This commit is contained in:
parent
a043071e3c
commit
c449ca5155
493 changed files with 1116 additions and 3903 deletions
|
@ -14,7 +14,7 @@ class AccountEmailProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->assertValue('@email', $this->user->email)
|
||||
->type('@email', 'new.email@example.com')
|
||||
->type('@password', 'Password123')
|
||||
|
@ -34,7 +34,7 @@ class AccountEmailProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->assertMissing('@email ~ .input-help.error')
|
||||
->type('@email', 'admin')
|
||||
->assertVisible('@email ~ .input-help.error')
|
||||
|
@ -51,7 +51,7 @@ class AccountEmailProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->type('@email', 'new.email@example.com')
|
||||
->click('@submit')
|
||||
->assertFocused('@password')
|
||||
|
|
|
@ -14,7 +14,7 @@ class AccountPasswordProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->type('@current_password', self::$userPassword)
|
||||
->assertMissing('@new_password ~ .input-help.error')
|
||||
->type('@new_password', 'test')
|
||||
|
@ -42,7 +42,7 @@ class AccountPasswordProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->type('@current_password', 'badpassword')
|
||||
->type('@new_password', 'testtest')
|
||||
->type('@confirm_password', 'testtest')
|
||||
|
|
|
@ -17,7 +17,7 @@ class TwoFactorAuthenticationProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->assertMissing('.modal-mask')
|
||||
->click('@2fa_button')
|
||||
->waitFor('@2fa_modal')
|
||||
|
@ -42,7 +42,7 @@ class TwoFactorAuthenticationProcessTest extends DashboardTestCase
|
|||
{
|
||||
$this->browse(function (PterodactylBrowser $browser) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->click('@2fa_button')
|
||||
->waitForText(trans('dashboard/account.two_factor.setup.title'))
|
||||
->assertFocused('@2fa_token')
|
||||
|
@ -76,7 +76,7 @@ class TwoFactorAuthenticationProcessTest extends DashboardTestCase
|
|||
*/
|
||||
public function testTwoFactorCanBeDisabled()
|
||||
{
|
||||
$secret = (new Google2FA)->generateSecretKey(16);
|
||||
$secret = (new Google2FA())->generateSecretKey(16);
|
||||
|
||||
$this->user->update([
|
||||
'use_totp' => true,
|
||||
|
@ -85,7 +85,7 @@ class TwoFactorAuthenticationProcessTest extends DashboardTestCase
|
|||
|
||||
$this->browse(function (PterodactylBrowser $browser) use ($secret) {
|
||||
$browser->loginAs($this->user)
|
||||
->visit(new AccountPage)
|
||||
->visit(new AccountPage())
|
||||
->click('@2fa_button')
|
||||
->waitForText(trans('dashboard/account.two_factor.disable.title'))
|
||||
->click('@2fa_cancel')
|
||||
|
|
Reference in a new issue