Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,17 @@ jobs:
"tests/search_test.py",
"tests/file_test.py",
"tests/dedupe_test.py",
"tests/announcement_banner_test.py",
"tests/close_old_findings_dedupe_test.py",
"tests/close_old_findings_test.py",
"tests/false_positive_history_test.py",
"tests/check_various_pages.py",
# "tests/import_scanner_test.py",
# "tests/zap.py",
"tests/notifications_test.py",
"tests/tool_config.py",
"openapi-validatator",

]
os: [alpine, debian]
fail-fast: false
Expand Down
8 changes: 8 additions & 0 deletions docker/entrypoint-integration-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,14 @@ else
# echo "Error: Zap integration test failed"; exit 1
# fi

test="Notifications tests"
echo "Running: $test"
if python3 tests/notifications_test.py ; then
success "$test"
else
fail "$test"
fi

test="Tool Config integration tests"
echo "Running: $test"
if python3 tests/tool_config.py ; then
Expand Down
2 changes: 1 addition & 1 deletion tests/close_old_findings_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def test_close_same_engagement_tests(self):
scan_environment = Select(driver.find_element(By.ID, "id_environment"))
scan_environment.select_by_visible_text("Development")
driver.find_element(By.ID, "id_close_old_findings").click()
driver.find_element(By.ID, "id_file").send_keys(self.relative_path / "dedupe_scans/dedupe_and_close_1.xml")
driver.find_element(By.ID, "id_file").send_keys(str(self.relative_path / "dedupe_scans/dedupe_and_close_1.xml"))
driver.find_elements(By.CLASS_NAME, "btn-primary")[1].click()

self.assertTrue(self.is_success_message_present(text="1 findings and closed 3 findings"))
Expand Down
6 changes: 5 additions & 1 deletion tests/false_positive_history_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,8 @@ def test_retroactive_edit_finding(self):
self.assert_is_false_positive(finding_1)
self.assert_is_false_positive(finding_2)
# Reactivate second finding
# PROBLEM: Upon saving of finding_2 it will be maked a false positive againm that's why this test case is skipped for now
# https://github.com/DefectDojo/django-DefectDojo/issues/8977
self.edit_toggle_false_positive(finding_2)
# Assert that both findings are active again
self.assert_is_active(finding_1)
Expand Down Expand Up @@ -163,7 +165,9 @@ def suite():
# Add each test the the suite to be run
# success and failure is output by the test
suite.addTest(ProductTest("test_create_product"))
suite.addTest(FalsePositiveHistoryTest("test_retroactive_edit_finding"))
# SKIP this test as the implemented logic will always mark finding1 and finding2 as false positive as long as at least one of them is false positive
# https://github.com/DefectDojo/django-DefectDojo/issues/8977
# suite.addTest(FalsePositiveHistoryTest("test_retroactive_edit_finding"))
suite.addTest(ProductTest("test_create_product"))
suite.addTest(FalsePositiveHistoryTest("test_retroactive_bulk_edit_finding"))
suite.addTest(ProductTest("test_delete_product"))
Expand Down