Skip to content

Commit ee03c81

Browse files
committed
test(e2e): name workspace sources by path in the drawer pin's page entry
Claude-Session: https://claude.ai/code/session_01FEkQ5osPMA12JX9fGcBzR3 Co-Authored-By: Claude <noreply@anthropic.com>
1 parent e39ee4e commit ee03c81

1 file changed

Lines changed: 8 additions & 3 deletions

File tree

‎ui/e2e/related-list-pinned-actions-width.spec.ts‎

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,11 @@ const source = (rel: string) => path.join(REPO_ROOT, rel);
6161
const THEME_CSS = source('packages/components/src/index.css');
6262
const RELATED_LIST = source('packages/plugin-detail/src/RelatedList.tsx');
6363
const ENLARGED_CONTEXT = source('packages/plugin-detail/src/relatedListCompact.ts');
64+
// The entry names workspace sources by path, never by package name: the e2e
65+
// type-check program must import no workspace package (it builds nothing first).
66+
const PLUGIN_GRID = source('packages/plugin-grid/src/index.tsx');
67+
const FIELDS = source('packages/fields/src/index.tsx');
68+
const REACT_BINDINGS = source('packages/react/src/index.ts');
6469

6570
/** The record drawer's page width (see the header). */
6671
const DRAWER_PAGE = 622;
@@ -112,9 +117,9 @@ function entry(): Plugin {
112117
const code = `
113118
import * as React from 'react';
114119
import { createRoot } from 'react-dom/client';
115-
import '@object-ui/plugin-grid';
116-
import { registerAllFields } from '@object-ui/fields';
117-
import { ActionProvider, SchemaRendererProvider } from '@object-ui/react';
120+
import ${JSON.stringify(PLUGIN_GRID)};
121+
import { registerAllFields } from ${JSON.stringify(FIELDS)};
122+
import { ActionProvider, SchemaRendererProvider } from ${JSON.stringify(REACT_BINDINGS)};
118123
import { RelatedList } from ${JSON.stringify(RELATED_LIST)};
119124
import { RelatedListEnlargedContext } from ${JSON.stringify(ENLARGED_CONTEXT)};
120125

0 commit comments

Comments
 (0)