summaryrefslogtreecommitdiff
path: root/imap4d/tests/testsuite.at
blob: 8a1c224841b016e9c8b2b2091d2c945a3ec307e6 (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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# This file is part of GNU Mailutils. -*- Autotest -*-
# Copyright (C) 2011-2012, 2014-2018 Free Software Foundation, Inc.
#
# GNU Mailutils is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 3, or (at
# your option) any later version.
#
# GNU Mailutils is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Mailutils.  If not, see <http://www.gnu.org/licenses/>.

m4_include([testsuite.inc])

m4_define([IMAP4D_HOMEDIR])

m4_define([IMAP4D_DEFAULT_OPTIONS],[dnl
--no-config dnl
--config-file=imap4d.conf dnl
--test dnl
])

m4_define([IMAP4D_PREAUTH_OPTIONS],[dnl
IMAP4D_DEFAULT_OPTIONS dnl
--preauth dnl
])

m4_define([IMAP4D_OPTIONS],[IMAP4D_PREAUTH_OPTIONS])

m4_define([IMAP4D_CONFIG],[make_config IMAP4D_HOMEDIR])

m4_define([IMAP4D_RUN],[IMAP4D_CONFIG
m4_if([$2],[expand],
[cat > input <<EOT
$1
EOT
],[dnl
AT_DATA([input],[$1])dnl
])
imap4d IMAP4D_OPTIONS < input | tr -d '\r'])

dnl ------------------------------------------------------------
dnl IMAP4D_CHECK([PREP], [INPUT], [STDOUT = `'], [STDERR = `'],
dnl              [FILTER = `'],[expand])
dnl
m4_pushdef([IMAP4D_CHECK],[
cwd=`pwd`
$1
AT_CHECK([
IMAP4D_RUN([$2],[$6]) | m4_if([$5],,[remove_uidvalidity],[$5])
],
[0],
[$3],
[$4])
])

AT_INIT
AT_TESTED([imap4d])
MUT_VERSION(imap4d)

m4_include([anystate.at])
m4_include([id.at])

m4_include([select.at])
m4_include([examine.at])
m4_include([status.at])
m4_include([expunge.at])
m4_include([close-expunge.at])
m4_include([create01.at])
m4_include([create02.at])

AT_BANNER([APPEND])
m4_include([append00.at])
m4_include([append01.at])

AT_BANNER([LIST])
m4_include([list.at])

AT_BANNER([SEARCH])
m4_include([search.at])

AT_BANNER([FETCH])
m4_include([fetch.at])

AT_BANNER([IDEF Checks])
m4_include([IDEF0955.at])
m4_include([IDEF0956.at])

Return to:

Send suggestions and report system problems to the System administrator.