forked from p15670423/monkey
UT: Add test for ICMPScanConfigurationSchema timeout validation
This commit is contained in:
parent
d8bccde276
commit
65ce50cac1
|
@ -126,6 +126,16 @@ def test_icmp_scan_configuration_schema():
|
||||||
assert config.timeout == TIMEOUT
|
assert config.timeout == TIMEOUT
|
||||||
|
|
||||||
|
|
||||||
|
def test_icmp_scan_configuration_schema__negative_timeout():
|
||||||
|
schema = ICMPScanConfigurationSchema()
|
||||||
|
|
||||||
|
negative_timeout_configuration = ICMP_CONFIGURATION.copy()
|
||||||
|
negative_timeout_configuration["timeout"] = -1
|
||||||
|
|
||||||
|
with pytest.raises(ValidationError):
|
||||||
|
schema.load(negative_timeout_configuration)
|
||||||
|
|
||||||
|
|
||||||
def test_tcp_scan_configuration_schema():
|
def test_tcp_scan_configuration_schema():
|
||||||
schema = TCPScanConfigurationSchema()
|
schema = TCPScanConfigurationSchema()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue