From 9aa06e138b00a3d5748a08f6858f949503f32a81 Mon Sep 17 00:00:00 2001 From: Josh Eckels Date: Wed, 23 Aug 2023 09:03:49 -0700 Subject: [PATCH] Be a little more patient for the store to load (#115) --- .../test/src/org/labkey/test/tests/IlluminaTest.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/genotyping/test/src/org/labkey/test/tests/IlluminaTest.java b/genotyping/test/src/org/labkey/test/tests/IlluminaTest.java index 65f16c26..9b3273a4 100644 --- a/genotyping/test/src/org/labkey/test/tests/IlluminaTest.java +++ b/genotyping/test/src/org/labkey/test/tests/IlluminaTest.java @@ -349,10 +349,14 @@ private void verifyIlluminaSampleSheet() Ext4FieldRef.getForLabel(this, a[0]).setValue(a[1]); } Ext4FieldRef combo = Ext4FieldRef.getForLabel(this, "Template"); + + waitFor(() -> + 3 == ((Long)combo.getEval("store.getCount()")).intValue(), + "Combo store does not have correct record number. Should be 3, but was " + ((Long)combo.getEval("store.getCount()")).intValue(), + WAIT_FOR_JAVASCRIPT); + combo.setValue(TEMPLATE_NAME); - int count = ((Long)combo.getEval("store.getCount()")).intValue(); - assertEquals("Combo store does not have correct record number", 3, count); sleep(50); assertEquals("Field value not set correctly", TEMPLATE_NAME, Ext4FieldRef.getForLabel(this, "Template").getValue()); _ext4Helper.clickTabContainingText("Preview Header");