diff --git a/frontend/src/chart_series.ts b/frontend/src/chart_series.ts index 07f643c12..4229e8d57 100644 --- a/frontend/src/chart_series.ts +++ b/frontend/src/chart_series.ts @@ -41,6 +41,7 @@ export function xaxis_type_for( NUMERIC_X_CHART_TYPES.includes(chart_type) ) return "numeric"; + return undefined; } /** diff --git a/tests/end-to-end/fixture.ts b/tests/end-to-end/fixture.ts index c975b9488..c6addb1c0 100644 --- a/tests/end-to-end/fixture.ts +++ b/tests/end-to-end/fixture.ts @@ -1,7 +1,7 @@ import path from "node:path"; import { test as base, expect } from "@playwright/test"; -const fixturesDirectory = path.resolve(__dirname, "fixtures"); +const fixturesDirectory = path.resolve(import.meta.dirname, "fixtures"); export const test = base.extend({ page: async ({ page }, use, testInfo) => { diff --git a/tests/end-to-end/fixtures/big-number/test.ts b/tests/end-to-end/fixtures/big-number/test.ts index a157eb9e9..8dd52dc06 100644 --- a/tests/end-to-end/fixtures/big-number/test.ts +++ b/tests/end-to-end/fixtures/big-number/test.ts @@ -1,4 +1,4 @@ -import { expect, test } from "../../fixture"; +import { expect, test } from "../../fixture.ts"; for (const theme of ["light", "dark"]) { test(`colored values match their cards in the ${theme} theme`, async ({ diff --git a/tests/end-to-end/fixtures/chart/test.ts b/tests/end-to-end/fixtures/chart/test.ts index 11bff5fcf..fda721243 100644 --- a/tests/end-to-end/fixtures/chart/test.ts +++ b/tests/end-to-end/fixtures/chart/test.ts @@ -1,4 +1,4 @@ -import { expect, type Page, test } from "../../fixture"; +import { expect, type Page, test } from "../../fixture.ts"; type ChartPoint = { x: string | number | Date; y: number | null }; diff --git a/tests/end-to-end/fixtures/form/test.ts b/tests/end-to-end/fixtures/form/test.ts index 7531b5915..247294731 100644 --- a/tests/end-to-end/fixtures/form/test.ts +++ b/tests/end-to-end/fixtures/form/test.ts @@ -1,4 +1,4 @@ -import { expect, test } from "../../fixture"; +import { expect, test } from "../../fixture.ts"; const fields = [ { selector: 'input[name="modern_text"]', name: "text" }, diff --git a/tests/end-to-end/fixtures/map/test.ts b/tests/end-to-end/fixtures/map/test.ts index f6c875661..a65650768 100644 --- a/tests/end-to-end/fixtures/map/test.ts +++ b/tests/end-to-end/fixtures/map/test.ts @@ -1,4 +1,4 @@ -import { expect, type Page, test } from "../../fixture"; +import { expect, type Page, test } from "../../fixture.ts"; const PARIS_WITHOUT_ITS_LONGITUDE = "48.85,"; const NOT_COORDINATES = "somewhere nice"; diff --git a/tests/end-to-end/package.json b/tests/end-to-end/package.json index e3d19fcbe..5a72f3067 100644 --- a/tests/end-to-end/package.json +++ b/tests/end-to-end/package.json @@ -1,6 +1,7 @@ { "name": "end-to-end", "version": "1.0.0", + "type": "module", "description": "", "main": "index.js", "scripts": { diff --git a/tsconfig.json b/tsconfig.json index 045c63f98..7d017ff49 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -6,9 +6,19 @@ "moduleResolution": "bundler", "noEmit": true, "allowImportingTsExtensions": true, + "erasableSyntaxOnly": true, + "isolatedModules": true, + "verbatimModuleSyntax": true, "strict": true, + "noImplicitOverride": true, + "noFallthroughCasesInSwitch": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "allowUnreachableCode": false, + "allowUnusedLabels": false, "noImplicitAny": false, - "types": [] + "types": [], + "noImplicitReturns": true }, "include": ["frontend/src"] }