From 61adedb816475d76fab5b289251f72146f9a6bb2 Mon Sep 17 00:00:00 2001 From: Felix Schnabel Date: Sat, 14 Sep 2024 22:42:23 +0200 Subject: [PATCH] Fix compilation error on master --- .../testerina/test/TestReportTest.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/testerina-integration-test/src/test/java/org/ballerinalang/testerina/test/TestReportTest.java b/tests/testerina-integration-test/src/test/java/org/ballerinalang/testerina/test/TestReportTest.java index a5c805a62008..4dd14939d477 100644 --- a/tests/testerina-integration-test/src/test/java/org/ballerinalang/testerina/test/TestReportTest.java +++ b/tests/testerina-integration-test/src/test/java/org/ballerinalang/testerina/test/TestReportTest.java @@ -317,10 +317,10 @@ private void validateCoverage() { } else if ("foo.annot".equals(moduleObj.get("name").getAsString())) { JsonObject fileObj = (JsonObject) moduleObj.get("sourceFiles").getAsJsonArray().get(0); Assert.assertEquals("main.bal", fileObj.get("name").getAsString()); - Assert.assertEquals(parser.parse(Arrays.toString(annotMainCovered)), - parser.parse(fileObj.get("coveredLines").getAsJsonArray().toString())); - Assert.assertEquals(parser.parse(Arrays.toString(annotMainMissed)), - parser.parse(fileObj.get("missedLines").getAsJsonArray().toString())); + Assert.assertEquals(JsonParser.parseString(Arrays.toString(annotMainCovered)), + JsonParser.parseString(fileObj.get("coveredLines").getAsJsonArray().toString())); + Assert.assertEquals(JsonParser.parseString(Arrays.toString(annotMainMissed)), + JsonParser.parseString(fileObj.get("missedLines").getAsJsonArray().toString())); Assert.assertEquals(annotMainPercentage, fileObj.get("coveragePercentage").getAsFloat()); // Verify coverage of module @@ -451,10 +451,10 @@ private void validateModuleWiseCoverage() { } else if ("foo.annot".equals(moduleObj.get("name").getAsString())) { JsonObject fileObj = (JsonObject) moduleObj.get("sourceFiles").getAsJsonArray().get(0); Assert.assertEquals("main.bal", fileObj.get("name").getAsString()); - Assert.assertEquals(parser.parse(Arrays.toString(annotMainCovered)), - parser.parse(fileObj.get("coveredLines").getAsJsonArray().toString())); - Assert.assertEquals(parser.parse(Arrays.toString(annotMainMissed)), - parser.parse(fileObj.get("missedLines").getAsJsonArray().toString())); + Assert.assertEquals(JsonParser.parseString(Arrays.toString(annotMainCovered)), + JsonParser.parseString(fileObj.get("coveredLines").getAsJsonArray().toString())); + Assert.assertEquals(JsonParser.parseString(Arrays.toString(annotMainMissed)), + JsonParser.parseString(fileObj.get("missedLines").getAsJsonArray().toString())); Assert.assertEquals(annotMainPercentage, fileObj.get("coveragePercentage").getAsFloat()); // Verify coverage of module