aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-07-11 22:05:14 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-07-11 22:05:14 +0100
commitb7b184bb90808c8db580488cb5169ae5f53d0fd7 (patch)
tree2b4626afa0a0487ea81a9e403d56509c5c052ffb /test
parent3ff2ccae3db08913bccfc0fd5c0ad98aaffca642 (diff)
downloadrspamd-b7b184bb90808c8db580488cb5169ae5f53d0fd7.tar.gz
rspamd-b7b184bb90808c8db580488cb5169ae5f53d0fd7.zip
Add url encoded tests.
Diffstat (limited to 'test')
-rw-r--r--test/functional/cases/scan_file.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/cases/scan_file.sh b/test/functional/cases/scan_file.sh
index 63626cae6..89a8d176c 100644
--- a/test/functional/cases/scan_file.sh
+++ b/test/functional/cases/scan_file.sh
@@ -11,4 +11,12 @@ run perl "$TEST_DIRNAME/cases/scan_file.pl" "file=$TEST_DIRNAME/messages/gtube.e
check_output 'GTUBE'
run perl "$TEST_DIRNAME/cases/scan_file.pl" "path=$TEST_DIRNAME/messages/gtube.eml"
+check_output 'GTUBE'
+
+# Hex encode every character
+_hex_name=`printf "$TEST_DIRNAME/messages/gtube.eml" | hexdump -v -e '/1 "%02x"' | sed 's/\(..\)/%\1/g'`
+run perl "$TEST_DIRNAME/cases/scan_file.pl" "${_hex_name}"
+check_output 'GTUBE'
+
+run perl "$TEST_DIRNAME/cases/scan_file.pl" "file=${_hex_name}"
check_output 'GTUBE' \ No newline at end of file