feat(runtime): add user-controlled turn recovery
This commit is contained in:
1 parent
ffa58aa5ef
commit
12029f8812
60 files changed
+4027
-169
No files matched your search
@@ -0,0 +1,19 @@
|
||||
import { beforeEach, describe, expect, it } from "vitest";
|
||||
|
||||
import {
|
||||
DEFAULT_LOCAL_PREFS,
|
||||
readLocalPreferences,
|
||||
writeLocalPreferences,
|
||||
} from "@/lib/local-preferences";
|
||||
|
||||
describe("local preferences", () => {
|
||||
beforeEach(() => localStorage.clear());
|
||||
|
||||
it("keeps browser notifications opt-in", () => {
|
||||
expect(DEFAULT_LOCAL_PREFS.browserNotifications).toBe(false);
|
||||
expect(readLocalPreferences().browserNotifications).toBe(false);
|
||||
|
||||
writeLocalPreferences({ ...DEFAULT_LOCAL_PREFS, browserNotifications: true });
|
||||
expect(readLocalPreferences().browserNotifications).toBe(true);
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user