-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed
Description
Aibolit fails when xml report is requested.
$ python -m aibolit recommend --folder test/integration/check --format=xml --full
Version 1.3.0 is available, but you are using 0.0.0
ignore: []
Traceback (most recent call last):
...
File "/home/me/aibolit/aibolit/__main__.py", line 536, in _process_file_result
if pattern.get('pattern_code'):
^^^^^^^^^^^
AttributeError: 'list' object has no attribute 'get'Test to reproduce the bug
diff --git a/test/recommend/test_recommend_pipeline.py b/test/recommend/test_recommend_pipeline.py
index c95986db..6e444249 100644
--- a/test/recommend/test_recommend_pipeline.py
+++ b/test/recommend/test_recommend_pipeline.py
@@ -156,6 +156,11 @@ class TestRecommendPipeline(TestCase):
mock_cmd = self.__create_mock_cmd()
create_xml_tree([], full_report=True, cmd=mock_cmd, exit_code=0)
+ def test_xml(self):
+ mock_input = self.__create_mock_input()
+ mock_cmd = self.__create_mock_cmd()
+ create_xml_tree(mock_input, cmd=mock_cmd, exit_code=2)
+
def test_text_format(self):
mock_input = self.__create_mock_input()
new_mock = format_converter_for_pattern(mock_input)Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed