Skip to content

Commit 17db846

Browse files
committed
load all state
1 parent f9c11ee commit 17db846

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

tests/src/Controller/ManageTokenTest.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ class ManageTokenTest extends TestCase
2727
/** @var \SimpleSAML\Configuration */
2828
protected Configuration $config;
2929

30+
/** @var \SimpleSAML\Configuration */
31+
protected $module_config;
32+
3033
/** @var \SimpleSAML\Logger */
3134
protected Logger $logger;
3235

@@ -51,6 +54,16 @@ protected function setUp(): void
5154
'simplesaml'
5255
);
5356

57+
$this->module_config = [];
58+
$this->module_config = Configuration::loadFromArray(
59+
[
60+
'registration' => ['use_inflow_registration' => true],
61+
]);
62+
63+
Configuration::setPreLoadedConfig($this->config, 'config.php');
64+
Configuration::setPreLoadedConfig($this->module_config, 'module_webauthn.php');
65+
66+
5467
$this->session = Session::getSessionFromRequest();
5568

5669
$this->logger = new class () extends Logger {

tests/src/Controller/WebAuthnTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,8 @@ public static function loadState(string $id, string $stage, bool $allowMissing =
9999
'FIDO2WantsRegister' => false,
100100
'FIDO2PasswordlessAuthMode' => false,
101101
'FIDO2AuthSuccessful' => false,
102-
'requestTokenModel' => 'something',
102+
'requestTokenModel' => 'something',
103+
'Source' => 'There is no real auth source in this test.',
103104
];
104105
}
105106
});

0 commit comments

Comments
 (0)