-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Filter which providers should be available to users
- Loading branch information
Showing
3 changed files
with
28 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,19 @@ | ||
<?php | ||
|
||
use function WordPressdotorg\Two_Factor\{}; | ||
//use function WordPressdotorg\Two_Factor\{}; | ||
|
||
defined( 'WPINC' ) || die(); | ||
|
||
class Test_WPorg_Two_Factor extends WP_UnitTestCase { | ||
public function test_two_factor_providers() { | ||
$actual = Two_Factor_Core::get_providers(); | ||
|
||
$this->assertArrayHasKey( 'Two_Factor_Totp', $actual ); | ||
$this->assertArrayHasKey( 'Two_Factor_Backup_Codes', $actual ); | ||
// @todo enable after https://github.com/WordPress/two-factor/issues/427 merges | ||
//$this->assertArrayHasKey( 'Two_Factor_WebAuthn', $actual ); | ||
|
||
$this->assertArrayNotHasKey( 'Two_Factor_Email', $actual ); | ||
$this->assertArrayNotHasKey( 'Two_Factor_Dummy', $actual ); | ||
} | ||
} |
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