diff options
| author | stuppie | 2026-09-04 12:52:46 -0600 |
|---|---|---|
| committer | stuppie | 2026-09-04 12:52:46 -0600 |
| commit | 4b705346968e38671ac9601cfa8444c944ecc8bd (patch) | |
| tree | 8aa812e35846a72b3965d136642ea84c689ec22a /tests/models/network/test_rdns.py | |
| parent | 493f131d6ffe1629ffb3610165271c3c87b32d3b (diff) | |
| download | generalresearch-4b705346968e38671ac9601cfa8444c944ecc8bd.tar.gz generalresearch-4b705346968e38671ac9601cfa8444c944ecc8bd.zip | |
remove a lot of if type_checking; fix model_rebuild errors. Remove all network models/managers/test/fixtures
Diffstat (limited to 'tests/models/network/test_rdns.py')
| -rw-r--r-- | tests/models/network/test_rdns.py | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/tests/models/network/test_rdns.py b/tests/models/network/test_rdns.py deleted file mode 100644 index 82126dd..0000000 --- a/tests/models/network/test_rdns.py +++ /dev/null @@ -1,40 +0,0 @@ -from __future__ import annotations - -from typing import TYPE_CHECKING - -import faker - -from generalresearch.models.network.rdns.execute import execute_rdns -from generalresearch.models.network.tool_run import ToolClass, ToolName - -if TYPE_CHECKING: - from generalresearch.managers.network.tool_run import ToolRunManager - -fake = faker.Faker() - - -def test_execute_rdns_grl(toolrun_manager: ToolRunManager): - ip = "65.19.129.53" - run = execute_rdns(ip=ip) - assert run.tool_name == ToolName.DIG - assert run.tool_class == ToolClass.RDNS - assert run.ip == ip - result = run.parsed - assert result.primary_hostname == "in1-smtp.grlengine.com" - assert result.primary_domain == "grlengine.com" - assert result.hostname_count == 1 - - toolrun_manager.create_rdns_run(run) - - -def test_execute_rdns_none(toolrun_manager: ToolRunManager): - ip = fake.ipv6() - run = execute_rdns(ip) - result = run.parsed - - assert result.primary_hostname is None - assert result.primary_domain is None - assert result.hostname_count == 0 - assert result.hostnames == [] - - toolrun_manager.create_rdns_run(run) |
