aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Authentication/TwoFactorAuth/RegistryTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/Authentication/TwoFactorAuth/RegistryTest.php')
-rw-r--r--tests/lib/Authentication/TwoFactorAuth/RegistryTest.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/tests/lib/Authentication/TwoFactorAuth/RegistryTest.php b/tests/lib/Authentication/TwoFactorAuth/RegistryTest.php
index 77e619d03a2..252b57e7983 100644
--- a/tests/lib/Authentication/TwoFactorAuth/RegistryTest.php
+++ b/tests/lib/Authentication/TwoFactorAuth/RegistryTest.php
@@ -119,12 +119,17 @@ class RegistryTest extends TestCase {
'provider_id' => 'twofactor_u2f',
]
]);
+
+ $calls = [
+ [new TwoFactorProviderDisabled('twofactor_u2f')],
+ [new TwoFactorProviderUserDeleted($user, 'twofactor_u2f')],
+ ];
$this->dispatcher->expects($this->exactly(2))
->method('dispatchTyped')
- ->withConsecutive(
- [new TwoFactorProviderDisabled('twofactor_u2f')],
- [new TwoFactorProviderUserDeleted($user, 'twofactor_u2f')],
- );
+ ->willReturnCallback(function () use (&$calls) {
+ $expected = array_shift($calls);
+ $this->assertEquals($expected, func_get_args());
+ });
$this->registry->deleteUserData($user);
}