Refactor API to use nested sessions/devices routers and fix test infrastructure

- Update API contract to use nested router structure for sessions and devices
  (me.sessions.list, me.devices.getInfo, etc.)
- Update frontend Svelte components to use new nested API paths
- Fix test assertion patterns for consistency (remove async () => wrappers)
- Fix test-db.ts findRepoRoot to use existsSync for directory checking
  (Bun.file().exists() returns false for directories)
- Add ESLint config override for test files to handle expect().rejects patterns

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
RevIQ
2026-01-10 17:17:50 +08:00
110 changed files with 2013 additions and 362 deletions

View File

@@ -13,4 +13,12 @@ export default [
"@typescript-eslint/require-await": "off",
},
},
{
// Disable certain rules for test files that have issues with expect().rejects
files: ["**/__tests__/**/*.ts"],
rules: {
"@typescript-eslint/await-thenable": "off",
"@typescript-eslint/no-confusing-void-expression": "off",
},
},
];