diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2009-02-19 21:07:28 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2009-02-19 21:07:28 +0200 |
commit | 62758ace16e756050f15b81e66ee5ab3bdd062ab (patch) | |
tree | 5ca9f04bdf00988185e3df1ad2bd21854d27121a /tests/etc | |
parent | 288ad3a8baf196011e791988b3251bbedb5f6cc2 (diff) | |
download | wydawca-62758ace16e756050f15b81e66ee5ab3bdd062ab.tar.gz wydawca-62758ace16e756050f15b81e66ee5ab3bdd062ab.tar.bz2 |
Improve testsuite
* src/mail.c (mail_send_message): Fix diagnostics.
(mail_stats): Bail out if admin_address is not defined.
* tests/mailstats.at: New file.
* tests/Makefile.am (TESTSUITE_AT): Add mailstats.at
* tests/testsuite.at: Add mailstats.at
* tests/etc/mailstats.rc: New file.
* tests/etc/Makefile.am (EXTRA_DIST): Add missing files.
* tests/etc/wydawca.rcin: Define admin-address, enforce newline at EOF.
* tests/notify-upl.at, tests/upload-dry.at, tests/upload.at: Fix descriptions.
Diffstat (limited to 'tests/etc')
-rw-r--r-- | tests/etc/Makefile.am | 8 | ||||
-rw-r--r-- | tests/etc/mailstats.rc | 42 | ||||
-rw-r--r-- | tests/etc/notify.rc | 16 | ||||
-rw-r--r-- | tests/etc/wydawca.rcin | 18 |
4 files changed, 83 insertions, 1 deletions
diff --git a/tests/etc/Makefile.am b/tests/etc/Makefile.am index 267beef..dd2ea5b 100644 --- a/tests/etc/Makefile.am +++ b/tests/etc/Makefile.am | |||
@@ -17,7 +17,13 @@ | |||
17 | GPGFILES = secring.gpg pubring.gpg | 17 | GPGFILES = secring.gpg pubring.gpg |
18 | noinst_DATA = @WYDAWCA_GPGFILES@ | 18 | noinst_DATA = @WYDAWCA_GPGFILES@ |
19 | 19 | ||
20 | EXTRA_DIST = pubring.asc secring.asc wydawca.rcin | 20 | EXTRA_DIST = \ |
21 | pubring.asc\ | ||
22 | secring.asc\ | ||
23 | wydawca.rcin\ | ||
24 | notify.rc\ | ||
25 | nullmail\ | ||
26 | mailstats.rc | ||
21 | 27 | ||
22 | GPG_FLAGS = --quiet --no-permission-warning --homedir . | 28 | GPG_FLAGS = --quiet --no-permission-warning --homedir . |
23 | pubring.gpg secring.gpg: $(srcdir)/pubring.asc $(srcdir)/secring.asc | 29 | pubring.gpg secring.gpg: $(srcdir)/pubring.asc $(srcdir)/secring.asc |
diff --git a/tests/etc/mailstats.rc b/tests/etc/mailstats.rc new file mode 100644 index 0000000..febad11 --- /dev/null +++ b/tests/etc/mailstats.rc | |||
@@ -0,0 +1,42 @@ | |||
1 | # This file is part of Wydawca testsuite | ||
2 | # Copyright (C) 2009 Sergey Poznyakoff | ||
3 | # | ||
4 | # Wydawca is free software; you can redistribute it and/or modify | ||
5 | # it under the terms of the GNU General Public License as published by | ||
6 | # the Free Software Foundation; either version 3, or (at your option) | ||
7 | # any later version. | ||
8 | # | ||
9 | # Wydawca is distributed in the hope that it will be useful, | ||
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | # GNU General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with Wydawca. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
17 | mail-statistics { | ||
18 | statistics all; | ||
19 | message <<EOT | ||
20 | Subject: Wydawca stats | ||
21 | |||
22 | This is to notify you that the recent run of wydawca | ||
23 | caused the following results: | ||
24 | |||
25 | errors ............................. ${stat:errors} | ||
26 | warning ............................ ${stat:warnings} | ||
27 | bad signatures ..................... ${stat:bad_signatures} | ||
28 | access violation attempts .......... ${stat:access_violations} | ||
29 | complete triplets .................. ${stat:complete_triplets} | ||
30 | incomplete triplets ................ ${stat:incomplete_triplets} | ||
31 | bad triplets ....................... ${stat:bad_triplets} | ||
32 | expired triplets ................... ${stat:expired_triplets} | ||
33 | triplet successes .................. ${stat:triplet_success} | ||
34 | files uploaded ..................... ${stat:uploads} | ||
35 | files archived ..................... ${stat:archives} | ||
36 | symlinks created ................... ${stat:symlinks} | ||
37 | symlinks removed ................... ${stat:rmsymlinks} | ||
38 | |||
39 | Regards, | ||
40 | Wydawca | ||
41 | EOT; | ||
42 | } | ||
diff --git a/tests/etc/notify.rc b/tests/etc/notify.rc index 00c6bda..8547b66 100644 --- a/tests/etc/notify.rc +++ b/tests/etc/notify.rc | |||
@@ -1,3 +1,19 @@ | |||
1 | # This file is part of Wydawca testsuite | ||
2 | # Copyright (C) 2009 Sergey Poznyakoff | ||
3 | # | ||
4 | # Wydawca is free software; you can redistribute it and/or modify | ||
5 | # it under the terms of the GNU General Public License as published by | ||
6 | # the Free Software Foundation; either version 3, or (at your option) | ||
7 | # any later version. | ||
8 | # | ||
9 | # Wydawca is distributed in the hope that it will be useful, | ||
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | # GNU General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with Wydawca. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
1 | # Notify the user about successful uploads | 17 | # Notify the user about successful uploads |
2 | notify-event { | 18 | notify-event { |
3 | event success; | 19 | event success; |
diff --git a/tests/etc/wydawca.rcin b/tests/etc/wydawca.rcin index f8a8ce4..452f7c9 100644 --- a/tests/etc/wydawca.rcin +++ b/tests/etc/wydawca.rcin | |||
@@ -1,3 +1,19 @@ | |||
1 | # This file is part of Wydawca testsuite | ||
2 | # Copyright (C) 2009 Sergey Poznyakoff | ||
3 | # | ||
4 | # Wydawca is free software; you can redistribute it and/or modify | ||
5 | # it under the terms of the GNU General Public License as published by | ||
6 | # the Free Software Foundation; either version 3, or (at your option) | ||
7 | # any later version. | ||
8 | # | ||
9 | # Wydawca is distributed in the hope that it will be useful, | ||
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | # GNU General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with Wydawca. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
1 | statistics all; | 17 | statistics all; |
2 | 18 | ||
3 | umask 022; | 19 | umask 022; |
@@ -66,6 +82,8 @@ directory ftp://wydawca.test { | |||
66 | archive none; | 82 | archive none; |
67 | } | 83 | } |
68 | 84 | ||
85 | admin-address "root@localhost"; | ||
69 | from-address "wydawca-noreply@localhost"; | 86 | from-address "wydawca-noreply@localhost"; |
70 | 87 | ||
71 | mailer "| @WD_CONFSRC@/nullmail @WD_DST@/mail.out -F ${sender} ${rcpt}"; | 88 | mailer "| @WD_CONFSRC@/nullmail @WD_DST@/mail.out -F ${sender} ${rcpt}"; |
89 | |||