summaryrefslogtreecommitdiff
path: root/plugins/managesieve/tests/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/managesieve/tests/src')
-rw-r--r--plugins/managesieve/tests/src/parser52
-rw-r--r--plugins/managesieve/tests/src/parser.out52
-rw-r--r--plugins/managesieve/tests/src/parser_body17
-rw-r--r--plugins/managesieve/tests/src/parser_date21
-rw-r--r--plugins/managesieve/tests/src/parser_enotify_a19
-rw-r--r--plugins/managesieve/tests/src/parser_enotify_b18
-rw-r--r--plugins/managesieve/tests/src/parser_imapflags7
-rw-r--r--plugins/managesieve/tests/src/parser_include7
-rw-r--r--plugins/managesieve/tests/src/parser_index24
-rw-r--r--plugins/managesieve/tests/src/parser_kep142
-rw-r--r--plugins/managesieve/tests/src/parser_kep14.out3
-rw-r--r--plugins/managesieve/tests/src/parser_notify_a18
-rw-r--r--plugins/managesieve/tests/src/parser_notify_b17
-rw-r--r--plugins/managesieve/tests/src/parser_prefix5
-rw-r--r--plugins/managesieve/tests/src/parser_relational6
-rw-r--r--plugins/managesieve/tests/src/parser_subaddress11
-rw-r--r--plugins/managesieve/tests/src/parser_vacation12
-rw-r--r--plugins/managesieve/tests/src/parser_vacation_seconds12
-rw-r--r--plugins/managesieve/tests/src/parser_variables12
19 files changed, 0 insertions, 315 deletions
diff --git a/plugins/managesieve/tests/src/parser b/plugins/managesieve/tests/src/parser
deleted file mode 100644
index c99b49814..000000000
--- a/plugins/managesieve/tests/src/parser
+++ /dev/null
@@ -1,52 +0,0 @@
-require ["fileinto","reject","envelope"];
-# rule:[spam]
-if anyof (header :contains "X-DSPAM-Result" "Spam")
-{
- fileinto "Spam";
- stop;
-}
-# rule:[test1]
-if anyof (header :contains :comparator "i;ascii-casemap" ["From","To"] "test@domain.tld")
-{
- discard;
- stop;
-}
-# rule:[test2]
-if anyof (not header :contains :comparator "i;octet" ["Subject"] "[test]", header :contains "Subject" "[test2]")
-{
- fileinto "test";
- stop;
-}
-# rule:[comments]
-if anyof (true) /* comment
- * "comment" #comment */ {
- /* comment */ stop;
-# comment
-}
-# rule:[reject]
-if size :over 5000K {
- reject "Message over 5MB size limit. Please contact me before sending this.";
-}
-# rule:[false]
-if false # size :over 5000K
-{
- stop; /* rule disabled */
-}
-# rule:[true]
-if true
-{
- stop;
-}
-fileinto "Test";
-# rule:[address test]
-if address :all :is "From" "nagios@domain.tld"
-{
- fileinto "domain.tld";
- stop;
-}
-# rule:[envelope test]
-if envelope :domain :is "From" "domain.tld"
-{
- fileinto "domain.tld";
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser.out b/plugins/managesieve/tests/src/parser.out
deleted file mode 100644
index 796343d4a..000000000
--- a/plugins/managesieve/tests/src/parser.out
+++ /dev/null
@@ -1,52 +0,0 @@
-require ["envelope","fileinto","reject"];
-# rule:[spam]
-if header :contains "X-DSPAM-Result" "Spam"
-{
- fileinto "Spam";
- stop;
-}
-# rule:[test1]
-if header :contains ["From","To"] "test@domain.tld"
-{
- discard;
- stop;
-}
-# rule:[test2]
-if anyof (not header :contains :comparator "i;octet" "Subject" "[test]", header :contains "Subject" "[test2]")
-{
- fileinto "test";
- stop;
-}
-# rule:[comments]
-if true
-{
- stop;
-}
-# rule:[reject]
-if size :over 5000K
-{
- reject "Message over 5MB size limit. Please contact me before sending this.";
-}
-# rule:[false]
-if false # size :over 5000K
-{
- stop;
-}
-# rule:[true]
-if true
-{
- stop;
-}
-fileinto "Test";
-# rule:[address test]
-if address :is "From" "nagios@domain.tld"
-{
- fileinto "domain.tld";
- stop;
-}
-# rule:[envelope test]
-if envelope :domain :is "From" "domain.tld"
-{
- fileinto "domain.tld";
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_body b/plugins/managesieve/tests/src/parser_body
deleted file mode 100644
index bd142ed8c..000000000
--- a/plugins/managesieve/tests/src/parser_body
+++ /dev/null
@@ -1,17 +0,0 @@
-require ["body","fileinto"];
-if body :raw :contains "MAKE MONEY FAST"
-{
- stop;
-}
-if body :content "text" :contains ["missile","coordinates"]
-{
- fileinto "secrets";
-}
-if body :content "audio/mp3" :contains ""
-{
- fileinto "jukebox";
-}
-if body :text :contains "project schedule"
-{
- fileinto "project/schedule";
-}
diff --git a/plugins/managesieve/tests/src/parser_date b/plugins/managesieve/tests/src/parser_date
deleted file mode 100644
index 06b00333f..000000000
--- a/plugins/managesieve/tests/src/parser_date
+++ /dev/null
@@ -1,21 +0,0 @@
-require ["comparator-i;ascii-numeric","date","fileinto","relational"];
-# rule:[date]
-if allof (date :originalzone :value "ge" :comparator "i;ascii-numeric" "date" "hour" "09")
-{
- fileinto "urgent";
-}
-# rule:[date-weekday]
-if date :is "received" "weekday" "0"
-{
- fileinto "weekend";
-}
-# rule:[date-zone]
-if date :zone "-0500" :value "gt" :comparator "i;ascii-numeric" "received" "iso8601" "2007-02-26T09:00:00-05:00"
-{
- stop;
-}
-# rule:[currentdate]
-if anyof (currentdate :is "weekday" "0", currentdate :value "lt" :comparator "i;ascii-numeric" "hour" "09", currentdate :value "ge" :comparator "i;ascii-numeric" "date" "2007-06-30")
-{
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_enotify_a b/plugins/managesieve/tests/src/parser_enotify_a
deleted file mode 100644
index 68a9ef5cc..000000000
--- a/plugins/managesieve/tests/src/parser_enotify_a
+++ /dev/null
@@ -1,19 +0,0 @@
-require ["enotify","variables"];
-# rule:[notify1]
-if header :contains "from" "boss@example.org"
-{
- notify :importance "1" :message "This is probably very important" "mailto:alm@example.com";
- stop;
-}
-# rule:[subject]
-if header :matches "Subject" "*"
-{
- set "subject" "${1}";
-}
-# rule:[from notify2]
-if header :matches "From" "*"
-{
- set "from" "${1}";
- notify :importance "3" :message "${from}: ${subject}" "mailto:alm@example.com";
-}
-
diff --git a/plugins/managesieve/tests/src/parser_enotify_b b/plugins/managesieve/tests/src/parser_enotify_b
deleted file mode 100644
index a3011bac2..000000000
--- a/plugins/managesieve/tests/src/parser_enotify_b
+++ /dev/null
@@ -1,18 +0,0 @@
-require ["enotify","envelope","variables"];
-# rule:[from]
-if envelope :matches "from" "*"
-{
- set "env_from" " [really: ${1}]";
-}
-# rule:[subject]
-if header :matches "Subject" "*"
-{
- set "subject" "${1}";
-}
-# rule:[from notify]
-if address :matches "from" "*"
-{
- set "from_addr" "${1}";
- notify :message "${from_addr}${env_from}: ${subject}" "mailto:alm@example.com";
-}
-
diff --git a/plugins/managesieve/tests/src/parser_imapflags b/plugins/managesieve/tests/src/parser_imapflags
deleted file mode 100644
index e67bf7cfc..000000000
--- a/plugins/managesieve/tests/src/parser_imapflags
+++ /dev/null
@@ -1,7 +0,0 @@
-require ["imap4flags"];
-# rule:[imapflags]
-if header :matches "Subject" "^Test$"
-{
- setflag "\\Seen";
- addflag ["\\Answered","\\Deleted"];
-}
diff --git a/plugins/managesieve/tests/src/parser_include b/plugins/managesieve/tests/src/parser_include
deleted file mode 100644
index b5585a4ba..000000000
--- a/plugins/managesieve/tests/src/parser_include
+++ /dev/null
@@ -1,7 +0,0 @@
-require ["include"];
-include "script.sieve";
-# rule:[two]
-if true
-{
- include :optional "second.sieve";
-}
diff --git a/plugins/managesieve/tests/src/parser_index b/plugins/managesieve/tests/src/parser_index
deleted file mode 100644
index ca9f86d56..000000000
--- a/plugins/managesieve/tests/src/parser_index
+++ /dev/null
@@ -1,24 +0,0 @@
-require ["comparator-i;ascii-numeric","date","fileinto","index","relational"];
-# rule:[index-header1]
-if header :index 1 :last :contains "X-DSPAM-Result" "Spam"
-{
- fileinto "Spam";
- stop;
-}
-# rule:[index-header2]
-if header :index 2 :contains ["From","To"] "test@domain.tld"
-{
- discard;
- stop;
-}
-# rule:[index-address]
-if address :index 1 :is "From" "nagios@domain.tld"
-{
- fileinto "domain.tld";
- stop;
-}
-# rule:[index-date]
-if date :index 1 :last :zone "-0500" :value "gt" :comparator "i;ascii-numeric" "received" "iso8601" "2007-02-26T09:00:00-05:00"
-{
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_kep14 b/plugins/managesieve/tests/src/parser_kep14
deleted file mode 100644
index 1ded8d8d4..000000000
--- a/plugins/managesieve/tests/src/parser_kep14
+++ /dev/null
@@ -1,2 +0,0 @@
-# EDITOR Roundcube
-# EDITOR_VERSION 123
diff --git a/plugins/managesieve/tests/src/parser_kep14.out b/plugins/managesieve/tests/src/parser_kep14.out
deleted file mode 100644
index cb7faa7f8..000000000
--- a/plugins/managesieve/tests/src/parser_kep14.out
+++ /dev/null
@@ -1,3 +0,0 @@
-require ["variables"];
-set "EDITOR" "Roundcube";
-set "EDITOR_VERSION" "123";
diff --git a/plugins/managesieve/tests/src/parser_notify_a b/plugins/managesieve/tests/src/parser_notify_a
deleted file mode 100644
index e51e2aa8d..000000000
--- a/plugins/managesieve/tests/src/parser_notify_a
+++ /dev/null
@@ -1,18 +0,0 @@
-require ["notify","variables"];
-# rule:[notify1]
-if header :contains "from" "boss@example.org"
-{
- notify :low :message "This is probably very important";
- stop;
-}
-# rule:[subject]
-if header :matches "Subject" "*"
-{
- set "subject" "${1}";
-}
-# rule:[from notify2]
-if header :matches "From" "*"
-{
- set "from" "${1}";
- notify :high :method "mailto" :options "test@example.org" :message "${from}: ${subject}";
-}
diff --git a/plugins/managesieve/tests/src/parser_notify_b b/plugins/managesieve/tests/src/parser_notify_b
deleted file mode 100644
index f942e155f..000000000
--- a/plugins/managesieve/tests/src/parser_notify_b
+++ /dev/null
@@ -1,17 +0,0 @@
-require ["envelope","notify","variables"];
-# rule:[from]
-if envelope :matches "from" "*"
-{
- set "env_from" " [really: ${1}]";
-}
-# rule:[subject]
-if header :matches "Subject" "*"
-{
- set "subject" "${1}";
-}
-# rule:[from notify]
-if address :matches "from" "*"
-{
- set "from_addr" "${1}";
- notify :method "sms" :options "1234567890" :message "${from_addr}${env_from}: ${subject}";
-}
diff --git a/plugins/managesieve/tests/src/parser_prefix b/plugins/managesieve/tests/src/parser_prefix
deleted file mode 100644
index 9f6a33a1c..000000000
--- a/plugins/managesieve/tests/src/parser_prefix
+++ /dev/null
@@ -1,5 +0,0 @@
-# this is a comment
-# and the second line
-
-require ["variables"];
-set "b" "c";
diff --git a/plugins/managesieve/tests/src/parser_relational b/plugins/managesieve/tests/src/parser_relational
deleted file mode 100644
index 92c5e1a8e..000000000
--- a/plugins/managesieve/tests/src/parser_relational
+++ /dev/null
@@ -1,6 +0,0 @@
-require ["comparator-i;ascii-numeric","relational"];
-# rule:[redirect]
-if header :value "ge" :comparator "i;ascii-numeric" "X-Spam-score" "14"
-{
- redirect "test@test.tld";
-}
diff --git a/plugins/managesieve/tests/src/parser_subaddress b/plugins/managesieve/tests/src/parser_subaddress
deleted file mode 100644
index e44555096..000000000
--- a/plugins/managesieve/tests/src/parser_subaddress
+++ /dev/null
@@ -1,11 +0,0 @@
-require ["envelope","fileinto","subaddress"];
-if envelope :user "To" "postmaster"
-{
- fileinto "postmaster";
- stop;
-}
-if envelope :detail :is "To" "mta-filters"
-{
- fileinto "mta-filters";
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_vacation b/plugins/managesieve/tests/src/parser_vacation
deleted file mode 100644
index 93026db45..000000000
--- a/plugins/managesieve/tests/src/parser_vacation
+++ /dev/null
@@ -1,12 +0,0 @@
-require ["vacation"];
-# rule:[test-vacation]
-if header :contains "Subject" "vacation"
-{
- vacation :days 1 text:
-# test
-test test /* test */
-test
-.
-;
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_vacation_seconds b/plugins/managesieve/tests/src/parser_vacation_seconds
deleted file mode 100644
index 75cbcae46..000000000
--- a/plugins/managesieve/tests/src/parser_vacation_seconds
+++ /dev/null
@@ -1,12 +0,0 @@
-require ["vacation-seconds"];
-# rule:[test-vacation]
-if header :contains "Subject" "vacation"
-{
- vacation :seconds 0 text:
-# test
-test test /* test */
-test
-.
-;
- stop;
-}
diff --git a/plugins/managesieve/tests/src/parser_variables b/plugins/managesieve/tests/src/parser_variables
deleted file mode 100644
index bd5941c02..000000000
--- a/plugins/managesieve/tests/src/parser_variables
+++ /dev/null
@@ -1,12 +0,0 @@
-require ["variables"];
-set "honorific" "Mr";
-set "vacation" text:
-Dear ${HONORIFIC} ${last_name},
-I am out, please leave a message after the meep.
-.
-;
-set :length "b" "${a}";
-set :lower "b" "${a}";
-set :upperfirst "b" "${a}";
-set :upperfirst :lower "b" "${a}";
-set :quotewildcard "b" "Rock*";