diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2020-08-19 08:49:15 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2020-08-19 08:49:15 +0300 |
commit | cd3a5a6d98e23e20e5fad3b5da108c4a11a9032d (patch) | |
tree | 14983118500051ea440b232db692ae8f5bb4de73 | |
parent | d2eb03a3b9db683418cc0bd084915468e4968854 (diff) | |
download | mailutils-cd3a5a6d98e23e20e5fad3b5da108c4a11a9032d.tar.gz mailutils-cd3a5a6d98e23e20e5fad3b5da108c4a11a9032d.tar.bz2 |
libmailutils/tests: Use MU_CHECK for simple tests
* testsuite/testsuite.inc (MU_CHECK): Remove superfluous quoting.
* libmailutils/tests/modmesg.at: New file.
* libmailutils/tests/streams.at: New file.
* libmailutils/tests/strin.at: Minor change.
* libmailutils/tests/modmesg02.at: Remove.
* libmailutils/tests/streamshift.at: Remove.
* libmailutils/tests/strtoc.at: Remove.
* libmailutils/tests/t0-stream.at: Remove.
* libmailutils/tests/t1-stream.at: Remove.
* libmailutils/tests/getdelim.at: Remove.
* libmailutils/tests/modmesg00.at: Remove.
* libmailutils/tests/modmesg01.at: Remove.
* libmailutils/tests/modmesg03.at: Remove.
* libmailutils/tests/testsuite.at: Update.
* libmailutils/tests/Makefile.am: Update.
-rw-r--r-- | libmailutils/tests/Makefile.am | 11 | ||||
-rw-r--r-- | libmailutils/tests/getdelim.at | 12 | ||||
-rw-r--r-- | libmailutils/tests/modmesg.at (renamed from libmailutils/tests/modmesg02.at) | 47 | ||||
-rw-r--r-- | libmailutils/tests/modmesg00.at | 29 | ||||
-rw-r--r-- | libmailutils/tests/modmesg01.at | 31 | ||||
-rw-r--r-- | libmailutils/tests/modmesg03.at | 31 | ||||
-rw-r--r-- | libmailutils/tests/streams.at (renamed from libmailutils/tests/streamshift.at) | 34 | ||||
-rw-r--r-- | libmailutils/tests/strin.at | 11 | ||||
-rw-r--r-- | libmailutils/tests/strtoc.at | 19 | ||||
-rw-r--r-- | libmailutils/tests/t0-stream.at | 20 | ||||
-rw-r--r-- | libmailutils/tests/t1-stream.at | 20 | ||||
-rw-r--r-- | libmailutils/tests/testsuite.at | 18 | ||||
-rw-r--r-- | testsuite/testsuite.inc | 2 |
13 files changed, 76 insertions, 209 deletions
diff --git a/libmailutils/tests/Makefile.am b/libmailutils/tests/Makefile.am index b29e24cd7..e5065f73c 100644 --- a/libmailutils/tests/Makefile.am +++ b/libmailutils/tests/Makefile.am | |||
@@ -110,7 +110,6 @@ TESTSUITE_AT += \ | |||
110 | fsfolder02.at\ | 110 | fsfolder02.at\ |
111 | fsfolder03.at\ | 111 | fsfolder03.at\ |
112 | fsfolder04.at\ | 112 | fsfolder04.at\ |
113 | getdelim.at\ | ||
114 | hdrcpy.at\ | 113 | hdrcpy.at\ |
115 | hdrflt.at\ | 114 | hdrflt.at\ |
116 | htmlent.at\ | 115 | htmlent.at\ |
@@ -123,10 +122,7 @@ TESTSUITE_AT += \ | |||
123 | logstr.at\ | 122 | logstr.at\ |
124 | mailcap.at\ | 123 | mailcap.at\ |
125 | mimehdr.at\ | 124 | mimehdr.at\ |
126 | modmesg00.at\ | 125 | modmesg.at\ |
127 | modmesg01.at\ | ||
128 | modmesg02.at\ | ||
129 | modmesg03.at\ | ||
130 | modtofsaf.at\ | 126 | modtofsaf.at\ |
131 | msgset.at\ | 127 | msgset.at\ |
132 | parseopt00.at\ | 128 | parseopt00.at\ |
@@ -176,13 +172,10 @@ TESTSUITE_AT += \ | |||
176 | recenv.at\ | 172 | recenv.at\ |
177 | scantime.at\ | 173 | scantime.at\ |
178 | strftime.at\ | 174 | strftime.at\ |
179 | streamshift.at\ | 175 | streams.at\ |
180 | strerr.at\ | 176 | strerr.at\ |
181 | strin.at\ | 177 | strin.at\ |
182 | strout.at\ | 178 | strout.at\ |
183 | strtoc.at\ | ||
184 | t0-stream.at\ | ||
185 | t1-stream.at\ | ||
186 | url.at\ | 179 | url.at\ |
187 | url-comp.at\ | 180 | url-comp.at\ |
188 | xml.at\ | 181 | xml.at\ |
diff --git a/libmailutils/tests/getdelim.at b/libmailutils/tests/getdelim.at deleted file mode 100644 index 493412e64..000000000 --- a/libmailutils/tests/getdelim.at +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | AT_SETUP([getdelim]) | ||
2 | AT_CHECK([stream-getdelim], | ||
3 | [0], | ||
4 | [0: No buffering | ||
5 | 1: Linear buffering | ||
6 | 2: Linear buffering (small buffer) | ||
7 | 3: Full buffering (big buffer) | ||
8 | 4: Full buffering (moderate buffer) | ||
9 | 5: Full buffering (small buffer) | ||
10 | ]) | ||
11 | AT_CLEANUP | ||
12 | |||
diff --git a/libmailutils/tests/modmesg02.at b/libmailutils/tests/modmesg.at index a4813fa11..f868205b9 100644 --- a/libmailutils/tests/modmesg02.at +++ b/libmailutils/tests/modmesg.at | |||
@@ -14,11 +14,32 @@ | |||
14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
15 | # along with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>. |
16 | 16 | ||
17 | AT_SETUP([modify body]) | 17 | MU_CHECK([unmodified message], |
18 | AT_KEYWORDS([modmesg02]) | 18 | [modmesg00], |
19 | [modmesg], | ||
20 | [0], | ||
21 | [From: root | ||
22 | |||
23 | This is a test message. | ||
24 | oo | ||
25 | ]) | ||
26 | |||
27 | MU_CHECK([add headers], | ||
28 | [modmesg01], | ||
29 | [modmesg -a To:gray@localhost -a Subject:test], | ||
30 | [0], | ||
31 | [From: root | ||
32 | To: gray@localhost | ||
33 | Subject: test | ||
34 | |||
35 | This is a test message. | ||
36 | oo | ||
37 | ]) | ||
19 | 38 | ||
20 | AT_CHECK([modmesg -t "word\n"], | 39 | MU_CHECK([modify body], |
21 | [0], | 40 | [modmesg02], |
41 | [modmesg -t "word\n"], | ||
42 | [0], | ||
22 | [From: root | 43 | [From: root |
23 | 44 | ||
24 | This is a test message. | 45 | This is a test message. |
@@ -26,13 +47,25 @@ oo | |||
26 | word | 47 | word |
27 | ]) | 48 | ]) |
28 | 49 | ||
29 | AT_CHECK([modmesg -l 0 -t "That"], | 50 | MU_CHECK([modify body 2], |
30 | [0], | 51 | [modmesg03], |
52 | [modmesg -l 0 -t "That"], | ||
53 | [0], | ||
31 | [From: root | 54 | [From: root |
32 | 55 | ||
33 | That is a test message. | 56 | That is a test message. |
34 | oo | 57 | oo |
35 | ]) | 58 | ]) |
36 | 59 | ||
37 | AT_CLEANUP | 60 | MU_CHECK([modify headers and body], |
61 | [modmesg03], | ||
62 | [modmesg -a To:gray@localhost -a Subject:test -l 0 -t "That"], | ||
63 | [0], | ||
64 | [From: root | ||
65 | To: gray@localhost | ||
66 | Subject: test | ||
67 | |||
68 | That is a test message. | ||
69 | oo | ||
70 | ]) | ||
38 | 71 | ||
diff --git a/libmailutils/tests/modmesg00.at b/libmailutils/tests/modmesg00.at deleted file mode 100644 index 60758e5ad..000000000 --- a/libmailutils/tests/modmesg00.at +++ /dev/null | |||
@@ -1,29 +0,0 @@ | |||
1 | # This file is part of GNU Mailutils. -*- Autotest -*- | ||
2 | # Copyright (C) 2011-2020 Free Software Foundation, Inc. | ||
3 | # | ||
4 | # GNU Mailutils is free software; you can redistribute it and/or | ||
5 | # modify it under the terms of the GNU General Public License as | ||
6 | # published by the Free Software Foundation; either version 3, or (at | ||
7 | # your option) any later version. | ||
8 | # | ||
9 | # GNU Mailutils is distributed in the hope that it will be useful, but | ||
10 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
12 | # General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
17 | AT_SETUP([unmodified message]) | ||
18 | AT_KEYWORDS([modmesg00]) | ||
19 | |||
20 | AT_CHECK([modmesg], | ||
21 | [0], | ||
22 | [From: root | ||
23 | |||
24 | This is a test message. | ||
25 | oo | ||
26 | ]) | ||
27 | |||
28 | AT_CLEANUP | ||
29 | |||
diff --git a/libmailutils/tests/modmesg01.at b/libmailutils/tests/modmesg01.at deleted file mode 100644 index 3b93bf947..000000000 --- a/libmailutils/tests/modmesg01.at +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | # This file is part of GNU Mailutils. -*- Autotest -*- | ||
2 | # Copyright (C) 2011-2020 Free Software Foundation, Inc. | ||
3 | # | ||
4 | # GNU Mailutils is free software; you can redistribute it and/or | ||
5 | # modify it under the terms of the GNU General Public License as | ||
6 | # published by the Free Software Foundation; either version 3, or (at | ||
7 | # your option) any later version. | ||
8 | # | ||
9 | # GNU Mailutils is distributed in the hope that it will be useful, but | ||
10 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
12 | # General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
17 | AT_SETUP([add headers]) | ||
18 | AT_KEYWORDS([modmesg01]) | ||
19 | |||
20 | AT_CHECK([modmesg -a To:gray@localhost -a Subject:test], | ||
21 | [0], | ||
22 | [From: root | ||
23 | To: gray@localhost | ||
24 | Subject: test | ||
25 | |||
26 | This is a test message. | ||
27 | oo | ||
28 | ]) | ||
29 | |||
30 | AT_CLEANUP | ||
31 | |||
diff --git a/libmailutils/tests/modmesg03.at b/libmailutils/tests/modmesg03.at deleted file mode 100644 index cf637147f..000000000 --- a/libmailutils/tests/modmesg03.at +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | # This file is part of GNU Mailutils. -*- Autotest -*- | ||
2 | # Copyright (C) 2011-2020 Free Software Foundation, Inc. | ||
3 | # | ||
4 | # GNU Mailutils is free software; you can redistribute it and/or | ||
5 | # modify it under the terms of the GNU General Public License as | ||
6 | # published by the Free Software Foundation; either version 3, or (at | ||
7 | # your option) any later version. | ||
8 | # | ||
9 | # GNU Mailutils is distributed in the hope that it will be useful, but | ||
10 | # WITHOUT ANY WARRANTY; without even the impl |