Example #1
0
 def _handle_analysis_tags(self, fw, plugin):
     self.tag_queue.put(check_tags(fw, plugin))
     return add_tags_to_object(fw, plugin)
Example #2
0
def test_check_tags_missing_root_uid():
    result = check_tags(TEST_TEXT_FILE, 'mock_plugin')
    assert result['notags']
Example #3
0
def test_check_tags_no_tags():
    result = check_tags(TEST_TEXT_FILE, 'dummy')
    assert result['notags']
Example #4
0
def test_check_tags_no_analysis():
    result = check_tags(TEST_TEXT_FILE, 'non_existing_analysis')
    assert result['notags']
Example #5
0
def test_check_tags_found():
    result = check_tags(TEST_TEXT_FILE, 'mock_plugin')
    assert not result['notags']
    assert result['tags'] == {'some_stuff': 'anything'}
Example #6
0
def test_check_tags_bad_type():
    result = check_tags(TEST_TEXT_FILE, 'mock_plugin')
    assert result['notags']