|
41 | 41 | import java.util.Set; |
42 | 42 |
|
43 | 43 | import static org.junit.Assert.assertEquals; |
| 44 | +import static org.junit.Assert.assertNotEquals; |
44 | 45 | import static org.junit.Assert.assertTrue; |
45 | 46 |
|
46 | 47 | @Category({MS2.class, Daily.class}) |
@@ -71,13 +72,11 @@ protected void setupMS2() |
71 | 72 | protected void verifyMS2() |
72 | 73 | { |
73 | 74 | verifyFirstRun(); |
74 | | - |
75 | 75 | validateSecondRun(); |
76 | | - |
77 | 76 | validateRunGroups(); |
78 | | - |
79 | 77 | queryValidationTest(); |
80 | 78 | pepXMLtest(); |
| 79 | + validateContainerFilter(); |
81 | 80 | } |
82 | 81 |
|
83 | 82 | private void verifyFirstRun() |
@@ -921,7 +920,7 @@ private void validateRunGroups() |
921 | 920 | verifyGroupAudit(); |
922 | 921 | } |
923 | 922 |
|
924 | | - //verify audit trail registers runs added to or removed from groups. |
| 923 | + //verify audit trail registers runs added to or removed from groups. |
925 | 924 | private void verifyGroupAudit() |
926 | 925 | { |
927 | 926 | List<Map<String, Object>> rows = executeSelectRowCommand("auditLog", "ExperimentAuditEvent").getRows(); |
@@ -1224,4 +1223,40 @@ public Set<String> getFilters() |
1224 | 1223 | } |
1225 | 1224 | return result; |
1226 | 1225 | } |
| 1226 | + |
| 1227 | + /** |
| 1228 | + * Issue 52245 - container filter not getting propagated to run group lookup |
| 1229 | + */ |
| 1230 | + private void validateContainerFilter() |
| 1231 | + { |
| 1232 | + // create a run group at the project level |
| 1233 | + goToProjectHome(getProjectName()); |
| 1234 | + clickAndWait(Locator.linkWithText("Run Groups")); |
| 1235 | + clickButton("Create Run Group"); |
| 1236 | + setFormElement(Locator.name("name"), RUN_GROUP3_NAME); |
| 1237 | + clickButton("Submit"); |
| 1238 | + |
| 1239 | + navigateToFolder(FOLDER_NAME); |
| 1240 | + DataRegionTable runsTable = new DataRegionTable(REGION_NAME_SEARCH_RUNS, this); |
| 1241 | + runsTable.checkAllOnPage(); |
| 1242 | + runsTable.clickHeaderMenu("Add to run group", RUN_GROUP3_NAME); |
| 1243 | + |
| 1244 | + goToProjectHome(getProjectName()); |
| 1245 | + goToSchemaBrowser(); |
| 1246 | + DataRegionTable dataTable = viewQueryData("ms2", "XTandemPeptides"); |
| 1247 | + dataTable.setContainerFilter(DataRegionTable.ContainerFilterType.CURRENT_AND_SUBFOLDERS); |
| 1248 | + |
| 1249 | + _customizeViewsHelper.openCustomizeViewPanel(); |
| 1250 | + _customizeViewsHelper.addColumn(new String[]{"Fraction", "Run", "ExperimentRunLSID", "RunGroups"}); |
| 1251 | + _customizeViewsHelper.applyCustomView(); |
| 1252 | + assertNotEquals("All rows should have a value for the run group", 0, dataTable.getDataRowCount()); |
| 1253 | + |
| 1254 | + // validate a single run group with the expected label |
| 1255 | + Set<String> runGroups = new HashSet<>(dataTable.getColumnDataAsText("RunGroups")); |
| 1256 | + assertEquals("Incorrect number of run groups", 1, runGroups.size()); |
| 1257 | + assertEquals("Invalid run group label", RUN_GROUP3_NAME, runGroups.iterator().next()); |
| 1258 | + |
| 1259 | + dataTable.setFilter("Fraction/Run/ExperimentRunLSID/RunGroups", "Is Blank"); |
| 1260 | + assertEquals("All rows should have a value for the run group", 0, dataTable.getDataRowCount()); |
| 1261 | + } |
1227 | 1262 | } |
0 commit comments