remove dup key
@@ -35,4 +35,4 @@ def test_output_from_result_json():
}
reformatted_result_json_file = os.devnull
reformatted_json = instance.output_from_result_json(json.dumps(result_json), reformatted_result_json_file)
- assert reformatted_json == [{'type': 'metadata', 'file_path': 'path/', 'id': '', 'results': {'tool': 'networkml', 'version': '0.0.0'}, 'type': 'metadata', 'version': '0.0.0', 'tool': 'networkml', 'data': {'mac_addresses': {'01:02:03:04:05:06': {'uid': 'testver', 'file_path': 'path/', 'pcap': '', 'pcap_key': '', 'pcap_labels': None, 'timestamp': 999, 'source_ip': '1.2.3.4', 'decisions': {'investigate': False}, 'classification': {'labels': ['bsomething', 'asomething', 'csomething'], 'confidences': (0.7, 0.6, 0.5)}}}}}, {'data': '', 'file_path': 'path/', 'id': '', 'results': {'tool': 'networkml', 'version': '0.0.0'}, 'tool': 'networkml', 'type': 'metadata'}] # nosec - fine in a test.
+ assert reformatted_json == [{'file_path': 'path/', 'id': '', 'results': {'tool': 'networkml', 'version': '0.0.0'}, 'type': 'metadata', 'version': '0.0.0', 'tool': 'networkml', 'data': {'mac_addresses': {'01:02:03:04:05:06': {'uid': 'testver', 'file_path': 'path/', 'pcap': '', 'pcap_key': '', 'pcap_labels': None, 'timestamp': 999, 'source_ip': '1.2.3.4', 'decisions': {'investigate': False}, 'classification': {'labels': ['bsomething', 'asomething', 'csomething'], 'confidences': (0.7, 0.6, 0.5)}}}}}, {'data': '', 'file_path': 'path/', 'id': '', 'results': {'tool': 'networkml', 'version': '0.0.0'}, 'tool': 'networkml', 'type': 'metadata'}] # nosec - fine in a test.
