Skip to content

Commit

Permalink
test: Use filename for cobertura parser, not class name
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonKagstrom committed Oct 29, 2023
1 parent b9626d7 commit a019c6a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tests/tools/parse_cobertura.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def lookupClassName(dom, name):
tags = dom.getElementsByTagName('class')

for tag in tags:
nameAttr = tag.attributes["name"]
nameAttr = tag.attributes["filename"]
if nameAttr.value == name:
return tag

Expand Down Expand Up @@ -48,7 +48,6 @@ def parseFile(filename):
return dom

def hitsPerLine(dom, fileName, lineNr):
fileName = fileName.replace(".", "_").replace("-", "_")

fileTag = lookupClassName(dom, fileName)

Expand Down

0 comments on commit a019c6a

Please sign in to comment.