You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
452 B
21 lines
452 B
import {
|
|
basicCheck,
|
|
describe,
|
|
disableLocalStorage,
|
|
expect,
|
|
it,
|
|
} from "./testing.ts";
|
|
import { LocalStorage } from "./local.ts";
|
|
|
|
describe(LocalStorage, () => {
|
|
it("uses localStorage as storage", async () => {
|
|
const storage = new LocalStorage();
|
|
await basicCheck(storage);
|
|
|
|
await disableLocalStorage(async () => {
|
|
expect(() => new LocalStorage()).toThrow(
|
|
"localStorage not available",
|
|
);
|
|
});
|
|
});
|
|
});
|
|
|