Skip to content

Commit

Permalink
Remove file type from result file location (#14)
Browse files Browse the repository at this point in the history
Signed-off-by: patrickpa <[email protected]>
  • Loading branch information
patrickpa authored Jul 8, 2024
1 parent 1ad7113 commit 74cd1b3
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 7 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,6 @@ def main():
issue_id=issue_id,
row=1,
column=0,
file_type="odr",
description="Location for issue",
)

Expand Down
1 change: 0 additions & 1 deletion qc_baselib/models/result.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ class InertialLocationType(BaseXmlModel):
class FileLocationType(BaseXmlModel):
column: int = attr(name="column")
row: int = attr(name="row")
file_type: str = attr(name="fileType")


class LocationType(BaseXmlModel):
Expand Down
2 changes: 0 additions & 2 deletions qc_baselib/result.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,13 +259,11 @@ def add_file_location(
issue_id: int,
row: int,
column: int,
file_type: str,
description: str,
) -> None:
file_location = result.FileLocationType(
row=row,
column=column,
file_type=file_type,
)

bundle = self._get_checker_bundle(checker_bundle_name=checker_bundle_name)
Expand Down
2 changes: 1 addition & 1 deletion tests/data/result_test_output.xqar
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<AddressedRule ruleUID="test.com:qc:1.0.0:qwerty.qwerty"/>
<Issue issueId="0" description="Issue found at odr" level="3" ruleUID="test.com:qc:1.0.0:qwerty.qwerty">
<Locations description="Location for issue">
<FileLocation column="0" row="1" fileType="odr"/>
<FileLocation column="0" row="1"/>
</Locations>
<Locations description="Location for issue">
<XMLLocation xpath="/foo/test/path"/>
Expand Down
2 changes: 0 additions & 2 deletions tests/test_result.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@ def test_result_write() -> None:
issue_id=issue_id,
row=1,
column=0,
file_type="odr",
description="Location for issue",
)
result.add_xml_location(
Expand Down Expand Up @@ -439,7 +438,6 @@ def test_domain_specific_info_add():
issue_id=issue_id,
row=1,
column=0,
file_type="odr",
description="Location for issue",
)

Expand Down

0 comments on commit 74cd1b3

Please sign in to comment.