chore(lint): enforce type imports in tests

- Remove the broad test exception for consistent type imports
- Mark test-only core and helper imports as type imports where appropriate
- Keep targeted validation for affected engine tests
This commit is contained in:
Danila Poyarkov 2026-05-06 02:35:57 +03:00
parent b665d9c99e
commit a63ac93a3d
6 changed files with 6 additions and 7 deletions

View file

@ -167,7 +167,6 @@
"typescript/no-non-null-assertion": "off",
"no-unused-vars": "off",
"no-empty-function": "off",
"typescript/consistent-type-imports": "off",
"open-pencil/no-inline-named-types": "off",
"complexity": "off"
}

View file

@ -6,8 +6,8 @@ import {
exportFigFile,
importNodeChanges,
initCodec,
SceneGraph,
FigmaAPI,
type SceneGraph,
type SceneNode,
type Fill
} from '@open-pencil/core'

View file

@ -6,8 +6,8 @@ import {
exportFigFile,
importNodeChanges,
initCodec,
SceneGraph,
FigmaAPI,
type SceneGraph,
type SceneNode,
type Fill
} from '@open-pencil/core'

View file

@ -6,8 +6,8 @@ import {
initCodec,
parseFigFile,
renderNodesToImage,
SceneGraph,
SkiaRenderer,
type SceneGraph,
type SceneNode
} from '@open-pencil/core'

View file

@ -2,7 +2,7 @@ import { describe, expect, test } from 'bun:test'
import { FigmaAPI } from '@open-pencil/core'
import { ALL_TOOLS, getTool, setupToolTest, type ToolResult } from '#tests/helpers/tools'
import { getTool, setupToolTest, type ALL_TOOLS, type ToolResult } from '#tests/helpers/tools'
describe('find_nodes', () => {
test('finds by name', () => {

View file

@ -1,5 +1,5 @@
import { readFigFile, SceneGraph } from '@open-pencil/core'
import type { GridTrack, SceneNode } from '@open-pencil/core'
import { readFigFile } from '@open-pencil/core'
import type { GridTrack, SceneGraph, SceneNode } from '@open-pencil/core'
export function pageId(graph: SceneGraph) {
return graph.getPages()[0].id