Skip to content

Commit

Permalink
KnitrReportTest: use checkExpectedErrors() instead of pause/resume JS…
Browse files Browse the repository at this point in the history
… error checks
  • Loading branch information
labkey-nicka committed Feb 25, 2025
1 parent 0d4dbdf commit b95c150
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/org/labkey/test/tests/KnitrReportTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -199,13 +199,10 @@ private void verifyAdhocReportDependencies(String viewName, String dependencies)

createKnitrReport(rmdDependenciesReport, RReportHelper.ReportOption.knitrMarkdown);

pauseJsErrorChecker(); // Don't fail due to "$ is not a function"
{
_rReportHelper.clickReportTab();
waitForElement(Locator.id("mtcars_table"));
assertElementNotPresent(Locator.id("mtcars_table_wrapper")); // Created by jQuery
}
resumeJsErrorChecker();
_rReportHelper.clickReportTab();
waitForElement(Locator.id("mtcars_table"));
assertElementNotPresent(Locator.id("mtcars_table_wrapper")); // Created by jQuery
checkExpectedErrors(1); // JavaScript error: "$(...).dataTable is not a function"

// now set the dependencies
_rReportHelper.clickSourceTab();
Expand Down

0 comments on commit b95c150

Please sign in to comment.