Add board directory view (#1132)

* feat(directory): add board directory view

* fix(directory): populate board status

* style(directory): tighten board table

* docs(board manager): point board owners to manager

* fix(directory): show loading status

* style(directory): center board column in directory table

* perf(directory): cap board status checks

* style(directory): simplify board row links

* test(ci): stabilize coverage run

* test(ci): stabilize coverage harness

* test(ci): avoid async app flush act

* test(app): narrow layout harness coverage

* test(ci): stabilize app update distribution mock

* test(ci): preload app harness before route tests

* fix(directory): address final review findings
This commit is contained in:
Tommaso Casaburi
2026-05-19 23:34:33 +07:00
committed by GitHub
parent 4370e89174
commit cda1f7519f
62 changed files with 1572 additions and 171 deletions
+9 -1
View File
@@ -1,6 +1,7 @@
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
const testState = vi.hoisted(() => ({
appUpdateEnabled: true,
capacitorPlatform: 'web',
browserOpenMock: vi.fn(),
electronDownloadAndInstallUpdateMock: vi.fn(),
@@ -21,6 +22,12 @@ vi.mock('@capacitor/browser', () => ({
},
}));
vi.mock('../app-distribution', () => ({
get isAppUpdateEnabled() {
return testState.appUpdateEnabled;
},
}));
const createFetchResponse = (body: unknown, ok = true, status = 200) => ({
ok,
status,
@@ -39,6 +46,7 @@ const loadModule = async () => {
describe('app-update', () => {
beforeEach(() => {
vi.clearAllMocks();
testState.appUpdateEnabled = true;
testState.capacitorPlatform = 'web';
testState.browserOpenMock.mockReset();
testState.electronDownloadAndInstallUpdateMock.mockReset();
@@ -97,7 +105,7 @@ describe('app-update', () => {
});
it('disables update checks for F-Droid builds', async () => {
vi.stubEnv('VITE_APP_DISTRIBUTION', 'fdroid');
testState.appUpdateEnabled = false;
testState.capacitorPlatform = 'android';
const { applyAvailableAppUpdate, isAppUpdateEnabled, resolveAvailableAppUpdate } = await loadModule();