From 2999372aa2b28a0f1aea184ee20b0a84e5082988 Mon Sep 17 00:00:00 2001 From: Binal Patel Date: Tue, 14 Jul 2026 15:10:41 -0600 Subject: [PATCH 1/2] Fix row lookup in testAuditDetailRejectsRowIdFromOtherList getRowIndex(String) matches on primary-key value (the .select checkbox), not on a column value. LIST_Y is an IntList keyed on Key, so passing the Name value returned -1 and blew up in DataRegionTable.updateLink. Use the (columnIdentifier, value) overload against NAME_FIELD instead. --- src/org/labkey/test/tests/list/ListTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/labkey/test/tests/list/ListTest.java b/src/org/labkey/test/tests/list/ListTest.java index 01352ffc90..85e55b03e7 100644 --- a/src/org/labkey/test/tests/list/ListTest.java +++ b/src/org/labkey/test/tests/list/ListTest.java @@ -903,7 +903,7 @@ public void testAuditDetailRejectsRowIdFromOtherList() throws Exception .setText(NAME_FIELD + "\n" + LIST_Y_ROW_VALUE) .submit(); DataRegionTable yTable = new DataRegionTable("query", getDriver()); - yTable.clickEditRow(yTable.getRowIndex(LIST_Y_ROW_VALUE)); + yTable.clickEditRow(yTable.getRowIndex(NAME_FIELD, LIST_Y_ROW_VALUE)); setFormElement(Locator.name("quf_" + NAME_FIELD), LIST_Y_ROW_EDITED); clickButton("Submit"); From 0b86ffb7e7e4d7b8867df48562cb0cc24349bbd4 Mon Sep 17 00:00:00 2001 From: Binal Patel Date: Wed, 15 Jul 2026 09:43:17 -0600 Subject: [PATCH 2/2] Look up list id via ListManager query, not exp.Lists exp schema has no Lists query; the list module exposes list metadata through ListManager.ListManager. Matches the resolveListId pattern in ListMoveRowsTest. --- src/org/labkey/test/tests/list/ListTest.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/org/labkey/test/tests/list/ListTest.java b/src/org/labkey/test/tests/list/ListTest.java index 85e55b03e7..fec469a594 100644 --- a/src/org/labkey/test/tests/list/ListTest.java +++ b/src/org/labkey/test/tests/list/ListTest.java @@ -934,13 +934,13 @@ public void testAuditDetailRejectsRowIdFromOtherList() throws Exception private int lookupListId(Connection cn, String listName) throws Exception { - SelectRowsCommand cmd = new SelectRowsCommand("exp", "Lists"); - cmd.setColumns(List.of("RowId", "Name")); + SelectRowsCommand cmd = new SelectRowsCommand("ListManager", "ListManager"); + cmd.setColumns(List.of("ListId", "Name")); cmd.addFilter(new Filter("Name", listName, Filter.Operator.EQUAL)); SelectRowsResponse rs = cmd.execute(cn, getProjectName()); if (rs.getRows().isEmpty()) - throw new AssertionError("No exp.Lists row for " + listName); - return ((Number) rs.getRows().get(0).get("RowId")).intValue(); + throw new AssertionError("No ListManager row for " + listName); + return ((Number) rs.getRows().get(0).get("ListId")).intValue(); } private int lookupListAuditRowId(Connection cn, String listName) throws Exception