AssertionFailedError when running DRT | Andy Straw | 2012-05-10 12:28 |
Status: Closed | ||
Thanks for the pointer to the Admin console info. I got past the "assertions not enabled" problem - was my bad (I had set CATALINA_OPTS in my .cshrc, but had not re-sourced that file from the shell where I was starting tomcat. And in catalina.sh, I had set -ea in the wrong Java command - I didn't notice there were several). I ran into several other problems getting DRT to pass, but was able to use the assertion failure message and/or look at the stacktrace and source to figure out how to fix them. (had to set -DdevMode=true; modified source of BasicTest.java to allow Firefox/12, since that's what I'm running; had to configure site's Base Server URL to http://localhost:8080 - I had set it to http://<myhostname>.<mydomainName>:8080; had installed R, but had failed to configure it in LabKey). I've now hit a failed assertion I'm not sure how to fix. But first, a question about running this suite of tests: When I got this test failure, I notice that some test data that had been created didn't get cleaned up. For example, I see a couple of site users, a couple of site groups, a whole Study project and study folder with a bunch of data sets. Should I delete all these before re-running the tests, or does the test clean up before it re-runs? Below is the failure I'm getting now (my instance is built from 12.1 source). Please advise. Thanks. Andy Straw University of Rochester 14:48:47,835 =============== Completed StudyTest (5 of 5) ================= testSteps(org.labkey.test.tests.StudyTest) junit.framework.AssertionFailedError: Text 'AE-1:(VTN) AE Log' was not present 0 times. It was present 27 times at org.labkey.test.BaseSeleniumWebTest.assertTextPresent(BaseSeleniumWebTest.java:2491) at org.labkey.test.BaseSeleniumWebTest.assertTextPresent(BaseSeleniumWebTest.java:2473) at org.labkey.test.tests.StudyTest.verifyParticipantReports(StudyTest.java:145) at org.labkey.test.tests.StudyTest.doVerifySteps(StudyTest.java:109) at org.labkey.test.tests.StudyBaseTest.runUITests(StudyBaseTest.java:99) at org.labkey.test.tests.SimpleApiTest.doTestSteps(SimpleApiTest.java:77) at org.labkey.test.BaseSeleniumWebTest.testSteps(BaseSeleniumWebTest.java:1195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83) at junit.framework.JUnit4TestAdapter.run(JUnit4TestAdapter.java:39) at org.labkey.test.Runner.runTest(Runner.java:269) at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:520) at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:1060) at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:911) ======================= Time Report ======================== BasicTest passed - 1:11 11% SecurityTest passed - 2:15 20% FlowTest passed - 3:17 29% XTandemTest passed - 2:05 18% StudyTest ERROR - 2:29 22% ------------------------------------------------------------ Total duration: 11:20 |
||