forked from p34709852/monkey
Tests: Split up test_get_exploits_used_on_node()
This commit is contained in:
parent
8583303682
commit
79639610df
|
@ -9,12 +9,16 @@ from monkey_island.cc.services.reporting.exploitations.monkey_exploitation impor
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
def test_get_exploits_used_on_node():
|
def test_get_exploits_used_on_node__2_exploits():
|
||||||
exploits = get_exploits_used_on_node(NODE_DICT)
|
exploits = get_exploits_used_on_node(NODE_DICT)
|
||||||
assert sorted(exploits) == sorted(["Elastic Groovy Exploiter", "Drupal Server Exploiter"])
|
assert sorted(exploits) == sorted(["Elastic Groovy Exploiter", "Drupal Server Exploiter"])
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_exploits_used_on_node__duplicate_exploits():
|
||||||
exploits = get_exploits_used_on_node(NODE_DICT_DUPLICATE_EXPLOITS)
|
exploits = get_exploits_used_on_node(NODE_DICT_DUPLICATE_EXPLOITS)
|
||||||
assert exploits == ["Drupal Server Exploiter"]
|
assert exploits == ["Drupal Server Exploiter"]
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_exploits_used_on_node__failed():
|
||||||
exploits = get_exploits_used_on_node(NODE_DICT_FAILED_EXPLOITS)
|
exploits = get_exploits_used_on_node(NODE_DICT_FAILED_EXPLOITS)
|
||||||
assert exploits == []
|
assert exploits == []
|
||||||
|
|
Loading…
Reference in New Issue