diff --git a/tests/acceptance/features/apiAntivirus/antivirus.feature b/tests/acceptance/features/apiAntivirus/antivirus.feature index ee8d983748..87fcca24b9 100644 --- a/tests/acceptance/features/apiAntivirus/antivirus.feature +++ b/tests/acceptance/features/apiAntivirus/antivirus.feature @@ -259,3 +259,32 @@ Feature: antivirus | filename | newfilename | | eicar.com | virusFile1.txt | | eicar_com.zip | virusFile2.zip | + + @env-config + Scenario Outline: upload a file with virus smaller than the upload threshold + Given the config "ANTIVIRUS_MAX_SCAN_SIZE" has been set to "100" + And using DAV path + When user "Alice" uploads file "filesForUpload/filesWithVirus/eicar.com" to "/aFileWithVirus.txt" using the WebDAV API + Then the HTTP status code should be "201" + And user "Alice" should get a notification with subject "Virus found" and message: + | message | + | Virus found in aFileWithVirus.txt. Upload not possible. Virus: Win.Test.EICAR_HDB-1 | + And as "Alice" file "/aFileWithVirus.txt" should not exist + Examples: + | dav-path-version | + | old | + | new | + | spaces | + + @env-config + Scenario Outline: upload a file with virus larger than the upload threshold + Given the config "ANTIVIRUS_MAX_SCAN_SIZE" has been set to "100" + And using DAV path + When user "Alice" uploads file "filesForUpload/filesWithVirus/eicar_com.zip" to "/aFileWithVirus.txt" using the WebDAV API + Then the HTTP status code should be "201" + And as "Alice" file "/aFileWithVirus.txt" should exist + Examples: + | dav-path-version | + | old | + | new | + | spaces | \ No newline at end of file diff --git a/tests/acceptance/filesForUpload/filesWithVirus/eicarcom2.zip b/tests/acceptance/filesForUpload/filesWithVirus/eicarcom2.zip deleted file mode 100644 index 4bda6119ad..0000000000 Binary files a/tests/acceptance/filesForUpload/filesWithVirus/eicarcom2.zip and /dev/null differ