Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

test(grid): update cell detail action tests to use displayIndex for consistency

t8y211117eca8e1f
diff --git a/packages/app-tests/cellDetailPresentation.test.ts b/packages/app-tests/cellDetailPresentation.test.ts
index 742ac46c2a..2d04d11b21 100644
--- a/packages/app-tests/cellDetailPresentation.test.ts
+++ b/packages/app-tests/cellDetailPresentation.test.ts
@@ -86,6 +86,6 @@ test("cell detail action focuses the hovered cell before opening details", () =>
/function showCellDetailsForVisibleCell\(rowIndex: number, visibleColIdx: number, actualColIdx: number\)/,
);
assert.match(source, /selectSingleCell\(rowIndex, visibleColIdx\)/);
- assert.match(source, /@click\.stop="showCellDetailsForVisibleCell\(index, visibleColIdx, actualColIdx\)"/);
- assert.doesNotMatch(source, /@click\.stop="showCellDetails\(index, actualColIdx\)"/);
+ assert.match(source, /@click\.stop="showCellDetailsForVisibleCell\(item\.displayIndex, visibleColIdx, actualColIdx\)"/);
+ assert.doesNotMatch(source, /@click\.stop="showCellDetails\(item\.displayIndex, actualColIdx\)"/);
});
diff --git a/packages/app-tests/domDensitySource.test.ts b/packages/app-tests/domDensitySource.test.ts
index a60cd3fbec..c0e13c3938 100644
--- a/packages/app-tests/domDensitySource.test.ts
+++ b/packages/app-tests/domDensitySource.test.ts
@@ -6,7 +6,7 @@ const dataGridSource = readFileSync("apps/desktop/src/components/grid/DataGrid.v
test("data grid mounts the cell detail action only for the active cell", () => {
assert.match(dataGridSource, /cellDetailButtonVisible/);
- assert.match(dataGridSource, /v-if="cellDetailButtonVisible\(index, actualColIdx\)"/);
- assert.match(dataGridSource, /@mouseenter="onCellMouseenter\(index, visibleColIdx, actualColIdx\)"/);
+ assert.match(dataGridSource, /v-if="cellDetailButtonVisible\(item\.displayIndex, actualColIdx\)"/);
+ assert.match(dataGridSource, /@mouseenter="onCellMouseenter\(item\.displayIndex, visibleColIdx, actualColIdx\)"/);
assert.doesNotMatch(dataGridSource, /group-hover\/cell:flex/);
});