Update test format (#821)

* Lint tests, format JSON

* Update test formatting

---------

Co-authored-by: philon- <philon-@users.noreply.github.com>
This commit is contained in:
Jeremy Gallant
2025-08-31 21:30:11 -04:00
committed by GitHub
co-authored by philon-
parent ee131c3681
commit 90cf136b8c
13 changed files with 124 additions and 93 deletions
@@ -18,7 +18,7 @@ const mockSendAdminMessage = vi.fn();
vi.mock("@core/stores", () => ({
CurrentDeviceContext: {
_currentValue: { deviceId: 1234 },
_currentValue: { deviceId: 1234 },
},
useNodeDB: () => ({
updateFavorite: mockUpdateFavorite,
@@ -17,8 +17,8 @@ const mockToast = vi.fn();
const mockSendAdminMessage = vi.fn();
vi.mock("@core/stores", () => ({
CurrentDeviceContext: {
_currentValue: { deviceId: 1234 },
CurrentDeviceContext: {
_currentValue: { deviceId: 1234 },
},
useNodeDB: () => ({
updateIgnore: mockUpdateIgnore,
@@ -28,7 +28,7 @@ describe("useToast", () => {
vi.runAllTimers();
});
const toast = result.current.toasts[0];
const toast = result.current.toasts[0]!;
expect(result.current.toasts.length).toBe(1);
expect(toast.title).toBe("Backup Reminder");
expect(toast.description).toBe("Don't forget to backup!");