test(app): nothing of one person reaches the next

Two guarantees of step 7 had no test. An open studyset closes when the person changes (here: the server revokes the session, and the app starts anew with another anonymous person), and the next person sees none of it. PersonScope shows the person's app once their data is open, says so when it can't be opened and then leaves no unhandled error behind (checked by removing the handler: the test fails), and closes the person's data when it goes away.

testDependencies takes an optional openPerson for this, and the fake auth gateway can revoke the session.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-09-30 12:34:13 +02:00
commit 3fc51057f1
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -39,6 +39,9 @@ class FakeAuthGateway({var AuthStatus _status = const SignedOut()})
_set(const SignedOut());
}
/// Ends the session as when the server revokes this device's session.
void revokeSession() => _set(const SignedOut());
void _set(AuthStatus status) {
_status = status;
_changes.add(status);