blob: c58bbc009cbb1d996e56d1bd9fa6d47184bd04e2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
require "vnd.dovecot.testsuite";
require "vnd.dovecot.environment";
require "variables";
test "default-mailbox" {
if not environment :is "vnd.dovecot.default-mailbox" "INBOX" {
if environment :matches "vnd.dovecot.default-mailbox" "*" { set "env" "${1}"; }
test_fail "vnd.dovecot.default-mailbox environment returned invalid value(1): `${env}'";
}
}
test "username" {
if not environment :contains "vnd.dovecot.username" "" {
test_fail "vnd.dovecot.username environment does not exist";
}
}
test_config_set "sieve_env_display_name" "Jan Jansen";
test_config_reload :extension "vnd.dovecot.environment";
test "config" {
if not environment :contains "vnd.dovecot.config.display_name" "" {
test_fail "vnd.dovecot.config.display_name environment does not exist";
}
if not environment :is "vnd.dovecot.config.display_name" "Jan Jansen" {
test_fail "vnd.dovecot.config.display_name environment has wrong value";
}
}
|