Skip to content

Commit 8fbb42e

Browse files
committed
Removing unnecessary regex since failure reason were moved to testDetails claim field
1 parent 10e2d80 commit 8fbb42e

File tree

2 files changed

+2
-13
lines changed

2 files changed

+2
-13
lines changed

html/index.js

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -382,7 +382,7 @@ function generateTestcaseSingleResultElement (currentTestResult, tableName, id,
382382
commonTestTextContent += '<td class="th-lg">' + currentTestResult.catalogInfo.description.replace(/\n/g, '<br>') + '</td>'
383383
commonTestTextContent += '<td>' + formattedDuration + '</td>'
384384
commonTestTextContent += '<td><b>' + currentTestResult.state + '</b>' + skippedReason + '</td>'
385-
commonTestTextContent += '<td>' + ansiUp.ansi_to_html(ExtractLog(currentTestResult.capturedTestOutput)).replace(/\n/g, '<br>') + '</td></tr>'
385+
commonTestTextContent += '<td>' + ansiUp.ansi_to_html(currentTestResult.capturedTestOutput).replace(/\n/g, '<br>') + '</td></tr>'
386386
const jsonObjNonCompliant = NonCompliantReasonTextToJson(currentTestResult.checkDetails)
387387
const jsonObjCompliant = CompliantReasonTextToJson(currentTestResult.checkDetails)
388388

@@ -799,17 +799,6 @@ function CompliantReasonTextToJson (reasonText) {
799799
return jsonObj
800800
}
801801

802-
// extract compliant json text from test output with regex
803-
function ExtractLog (fullLog) {
804-
const regex = /(.*){"CompliantObjectsOut"/
805-
const match = regex.exec(fullLog)
806-
let logWithNoReason = fullLog
807-
if (match) {
808-
logWithNoReason = match[1]
809-
}
810-
return logWithNoReason
811-
}
812-
813802
// create a list of object types present in json output
814803
function createTypeList (jsonData) {
815804
const objectTypes = new Map()

0 commit comments

Comments
 (0)