This repository has been archived by the owner on Dec 14, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update tests to use testmail accounts for email (#188)
- Loading branch information
Showing
20 changed files
with
109 additions
and
105 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,7 +53,7 @@ public static function setUpBeforeClass() | |
"accountName" => "", | ||
"issuer" => "", | ||
"secret" => "JBSWY3DPEHPK3PXP", | ||
"keyUri" => "otpauth://totp/Example:alice@google.com?secret=JBSWY3DPEHPK3PXP&issuer=Example", //? | ||
"keyUri" => "otpauth://totp/Example:alice@testmail.stormpath.com?secret=JBSWY3DPEHPK3PXP&issuer=Example", //? | ||
"base64QRImage" => "qrcode", | ||
"account" => [ | ||
"href" => "https://api.stormpath.com/v1/accounts/3w9hThWQ3uAT46sMuWY6dw" | ||
|
@@ -139,11 +139,11 @@ public function account_name_is_accessible() | |
/** @test */ | ||
public function account_name_is_settable() | ||
{ | ||
static::$testable->setAccountName('[email protected]'); | ||
static::assertEquals('[email protected]', static::$testable->getAccountName()); | ||
static::$testable->setAccountName('support@testmail.stormpath.com'); | ||
static::assertEquals('support@testmail.stormpath.com', static::$testable->getAccountName()); | ||
|
||
static::$testable->accountName = '[email protected]'; | ||
static::assertEquals('[email protected]', static::$testable->getAccountName()); | ||
static::$testable->accountName = 'php@testmail.stormpath.com'; | ||
static::assertEquals('php@testmail.stormpath.com', static::$testable->getAccountName()); | ||
} | ||
|
||
|
||
|
@@ -161,7 +161,7 @@ public function a_google_authenticator_factor_can_be_added_to_an_account() | |
$account = $this->setupNewAccount(); | ||
|
||
$gaFactor = new GoogleAuthenticatorFactor(); | ||
$gaFactor->accountName = '[email protected]'; | ||
$gaFactor->accountName = 'brian@testmail.stormpath.com'; | ||
$gaFactor->issuer = 'php-test'; | ||
$gaFactor->status = Stormpath::ENABLED; | ||
|
||
|
@@ -172,7 +172,7 @@ public function a_google_authenticator_factor_can_be_added_to_an_account() | |
$this->assertNull($factor->mostRecentChallenge); | ||
$this->assertEquals(Stormpath::ENABLED, $factor->status); | ||
$this->assertEquals(Stormpath::UNVERIFIED, $factor->verificationStatus); | ||
$this->assertEquals('[email protected]', $factor->accountName); | ||
$this->assertEquals('brian@testmail.stormpath.com', $factor->accountName); | ||
$this->assertEquals('php-test', $factor->issuer); | ||
|
||
$account->directory->delete(); | ||
|
@@ -192,7 +192,7 @@ private function setupNewAccount(\Stormpath\Resource\Directory $directory = null | |
'middleName' => 'Middle Name', | ||
'surname' => 'Surname', | ||
'username' => makeUniqueName('AccountTest smsFactor') . 'username', | ||
'email' => makeUniqueName('AccountTest smsFactor') .'@mailinator.com', | ||
'email' => makeUniqueName('AccountTest smsFactor') .'@testmail.stormpath.com', | ||
'password' => 'superP4ss!' | ||
]) | ||
); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.