mirror of
https://github.com/laramies/theHarvester.git
synced 2026-09-27 20:14:52 +02:00
17 lines
505 B
Python
17 lines
505 B
Python
import pytest
|
|
|
|
from theHarvester import __main__ as theharvester_main
|
|
|
|
|
|
@pytest.mark.parametrize('target', ['Example.COM.', 'WWW.Example.COM.'])
|
|
def test_normalize_hosts_for_storage_uses_the_parser_scope(target: str) -> None:
|
|
discovered_hosts: set[object] = {
|
|
'API.Example.COM.',
|
|
'example.com',
|
|
'badexample.com',
|
|
'example.com.attacker.test',
|
|
123,
|
|
}
|
|
|
|
assert theharvester_main._normalize_hosts_for_storage(discovered_hosts, target) == {'api.example.com'}
|