Changeset 5437 in subversion


Ignore:
Timestamp:
Nov 16, 2011 6:41:57 AM (18 months ago)
Author:
alec
Message:
  • Split test scripts by sieve extension
Location:
trunk/plugins/managesieve/tests
Files:
3 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/plugins/managesieve/tests/parser.phpt

    r4536 r5437  
    77 
    88$txt = ' 
    9 require ["fileinto","vacation","reject","relational","comparator-i;ascii-numeric","imapflags"]; 
     9require ["fileinto","reject"]; 
    1010# rule:[spam] 
    1111if anyof (header :contains "X-DSPAM-Result" "Spam") 
     
    2626        stop; 
    2727} 
    28 # rule:[test-vacation] 
    29 if anyof (header :contains "Subject" "vacation") 
    30 { 
    31         vacation :days 1 text: 
    32 # test 
    33 test test /* test */ 
    34 test 
    35 . 
    36 ; 
    37         stop; 
    38 } 
    3928# rule:[comments] 
    4029if anyof (true) /* comment 
     
    4736    reject "Message over 5MB size limit. Please contact me before sending this."; 
    4837} 
    49 # rule:[redirect] 
    50 if header :value "ge" :comparator "i;ascii-numeric" 
    51     ["X-Spam-score"] ["14"] {redirect "test@test.tld";} 
    52 # rule:[imapflags] 
    53 if header :matches "Subject" "^Test$" { 
    54     setflag "\\\\Seen"; 
    55     addflag ["\\\\Answered","\\\\Deleted"]; 
    56 } 
    5738'; 
    5839 
     
    6243?> 
    6344--EXPECT-- 
    64 require ["fileinto","vacation","reject","relational","comparator-i;ascii-numeric","imapflags"]; 
     45require ["fileinto","reject"]; 
    6546# rule:[spam] 
    6647if header :contains "X-DSPAM-Result" "Spam" 
     
    8162        stop; 
    8263} 
    83 # rule:[test-vacation] 
    84 if header :contains "Subject" "vacation" 
    85 { 
    86         vacation :days 1 text: 
    87 # test 
    88 test test /* test */ 
    89 test 
    90 . 
    91 ; 
    92         stop; 
    93 } 
    9464# rule:[comments] 
    9565if true 
     
    10272        reject "Message over 5MB size limit. Please contact me before sending this."; 
    10373} 
    104 # rule:[redirect] 
    105 if header :value "ge" :comparator "i;ascii-numeric" "X-Spam-score" "14" 
    106 { 
    107         redirect "test@test.tld"; 
    108 } 
    109 # rule:[imapflags] 
    110 if header :matches "Subject" "^Test$" 
    111 { 
    112         setflag "\\Seen"; 
    113         addflag ["\\Answered","\\Deleted"]; 
    114 } 
Note: See TracChangeset for help on using the changeset viewer.