diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/.gitignore | 1 | ||||
-rw-r--r-- | tests/Makefile.am | 8 | ||||
-rw-r--r-- | tests/accept.at | 8 | ||||
-rw-r--r-- | tests/atlocal.in | 2 | ||||
-rwxr-xr-x | tests/aux/in.test | 2 | ||||
-rw-r--r-- | tests/builtin.at | 16 | ||||
-rw-r--r-- | tests/chargen.c | 2 | ||||
-rw-r--r-- | tests/control.at | 8 | ||||
-rw-r--r-- | tests/cyclic.at | 39 | ||||
-rw-r--r-- | tests/env.at | 12 | ||||
-rw-r--r-- | tests/envglobal.at | 86 | ||||
-rw-r--r-- | tests/envop.at | 4 | ||||
-rw-r--r-- | tests/envtest.c | 2 | ||||
-rw-r--r-- | tests/expandenv.at | 50 | ||||
-rw-r--r-- | tests/inet.at | 6 | ||||
-rw-r--r-- | tests/iobuf.h | 2 | ||||
-rw-r--r-- | tests/lines.c | 3 | ||||
-rw-r--r-- | tests/maxinst.at | 8 | ||||
-rw-r--r-- | tests/nt.c | 2 | ||||
-rw-r--r-- | tests/passfd.at | 8 | ||||
-rw-r--r-- | tests/readtime.c | 2 | ||||
-rw-r--r-- | tests/recvfd.c | 2 | ||||
-rw-r--r-- | tests/redirect.at | 6 | ||||
-rw-r--r-- | tests/respawn.at | 8 | ||||
-rw-r--r-- | tests/ret-exec.at | 6 | ||||
-rw-r--r-- | tests/ret-notify.at | 6 | ||||
-rw-r--r-- | tests/shdnseq.at | 82 | ||||
-rw-r--r-- | tests/shell.at | 8 | ||||
-rw-r--r-- | tests/shutdown.at | 10 | ||||
-rw-r--r-- | tests/sigterm.at | 49 | ||||
-rw-r--r-- | tests/sigwait.c | 75 | ||||
-rw-r--r-- | tests/startup.at | 8 | ||||
-rw-r--r-- | tests/testsuite.at | 13 | ||||
-rw-r--r-- | tests/to.c | 2 | ||||
-rw-r--r-- | tests/version.at | 4 |
35 files changed, 466 insertions, 84 deletions
diff --git a/tests/.gitignore b/tests/.gitignore index 43d3848..1993da2 100644 --- a/tests/.gitignore +++ b/tests/.gitignore | |||
@@ -11,3 +11,4 @@ nt | |||
11 | recvfd | 11 | recvfd |
12 | readtime | 12 | readtime |
13 | chargen | 13 | chargen |
14 | sigwait | ||
diff --git a/tests/Makefile.am b/tests/Makefile.am index bfdc692..6724aea 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am | |||
@@ -1,5 +1,5 @@ | |||
1 | # This file is part of GNU Pies. | 1 | # This file is part of GNU Pies. |
2 | # Copyright (C) 2008-2020 Sergey Poznyakoff | 2 | # Copyright (C) 2008-2023 Sergey Poznyakoff |
3 | # | 3 | # |
4 | # GNU Pies is free software; you can redistribute it and/or modify | 4 | # GNU Pies is free software; you can redistribute it and/or modify |
5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
@@ -54,7 +54,9 @@ TESTSUITE_AT = \ | |||
54 | control.at\ | 54 | control.at\ |
55 | cyclic.at\ | 55 | cyclic.at\ |
56 | env.at\ | 56 | env.at\ |
57 | envglobal.at\ | ||
57 | envop.at\ | 58 | envop.at\ |
59 | expandenv.at\ | ||
58 | inet.at\ | 60 | inet.at\ |
59 | maxinst.at\ | 61 | maxinst.at\ |
60 | passfd.at\ | 62 | passfd.at\ |
@@ -62,15 +64,17 @@ TESTSUITE_AT = \ | |||
62 | redirect.at\ | 64 | redirect.at\ |
63 | ret-exec.at\ | 65 | ret-exec.at\ |
64 | ret-notify.at\ | 66 | ret-notify.at\ |
67 | sigterm.at\ | ||
65 | shell.at\ | 68 | shell.at\ |
66 | startup.at\ | 69 | startup.at\ |
70 | shdnseq.at\ | ||
67 | shutdown.at\ | 71 | shutdown.at\ |
68 | version.at | 72 | version.at |
69 | 73 | ||
70 | TESTSUITE = $(srcdir)/testsuite | 74 | TESTSUITE = $(srcdir)/testsuite |
71 | M4=m4 | 75 | M4=m4 |
72 | 76 | ||
73 | noinst_PROGRAMS = envtest to lines nt recvfd readtime chargen | 77 | noinst_PROGRAMS = envtest to lines nt recvfd readtime chargen sigwait |
74 | nt_SOURCES = nt.c iobuf.h | 78 | nt_SOURCES = nt.c iobuf.h |
75 | AM_CPPFLAGS = \ | 79 | AM_CPPFLAGS = \ |
76 | -I$(top_srcdir)/lib\ | 80 | -I$(top_srcdir)/lib\ |
diff --git a/tests/accept.at b/tests/accept.at index e12be02..0249ad6 100644 --- a/tests/accept.at +++ b/tests/accept.at | |||
@@ -1,5 +1,5 @@ | |||
1 | # This file is part of GNU pies testsuite. -*- Autotest -*- | 1 | # This file is part of GNU pies testsuite. -*- autotest -*- |
2 | # Copyright (C) 2019-2020 Sergey Poznyakoff | 2 | # Copyright (C) 2019-2023 Sergey Poznyakoff |
3 | # | 3 | # |
4 | # GNU pies is free software; you can redistribute it and/or modify | 4 | # GNU pies is free software; you can redistribute it and/or modify |
5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
@@ -40,7 +40,7 @@ _EOT | |||
40 | 40 | ||
41 | set -e | 41 | set -e |
42 | to 10 \ | 42 | to 10 \ |
43 | pies --foreground --stderr \ | 43 | pies --no-preprocessor --foreground --stderr \ |
44 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog | 44 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog |
45 | 45 | ||
46 | cat inlog | 46 | cat inlog |
@@ -51,4 +51,4 @@ cat log.err >&2 | |||
51 | the time | 51 | the time |
52 | stop | 52 | stop |
53 | ]) | 53 | ]) |
54 | AT_CLEANUP \ No newline at end of file | 54 | AT_CLEANUP |
diff --git a/tests/atlocal.in b/tests/atlocal.in index c043843..0e4695e 100644 --- a/tests/atlocal.in +++ b/tests/atlocal.in | |||
@@ -1,6 +1,6 @@ | |||
1 | # @configure_input@ -*- shell-script -*- | 1 | # @configure_input@ -*- shell-script -*- |
2 | # Configurable variable values for GNU Pies test suite. | 2 | # Configurable variable values for GNU Pies test suite. |
3 | # Copyright (C) 2016-2020 Sergey Poznyakoff | 3 | # Copyright (C) 2016-2023 Sergey Poznyakoff |
4 | 4 | ||
5 | PATH=@abs_builddir@:@abs_top_builddir@/src:$srcdir:$PATH | 5 | PATH=@abs_builddir@:@abs_top_builddir@/src:$srcdir:$PATH |
6 | XFAILFILE=$abs_builddir/.badversion | 6 | XFAILFILE=$abs_builddir/.badversion |
diff --git a/tests/aux/in.test b/tests/aux/in.test index 1fae034..54b546a 100755 --- a/tests/aux/in.test +++ b/tests/aux/in.test | |||
@@ -4,7 +4,7 @@ FILE=${1:?} | |||
4 | IFS=' | 4 | IFS=' |
5 | ' | 5 | ' |
6 | : ${PIESCTL:=piesctl} | 6 | : ${PIESCTL:=piesctl} |
7 | PIESCTL="$PIESCTL --no-netrc${PIES_CTLSOCK:+ --url=}$PIES_CTLSOCK" | 7 | PIESCTL="$PIESCTL --config-file=/dev/null --no-netrc${PIES_CTLSOCK:+ --url=}$PIES_CTLSOCK" |
8 | while read COMMAND ARG | 8 | while read COMMAND ARG |
9 | do | 9 | do |
10 | echo $COMMAND $ARG >> $FILE | 10 | echo $COMMAND $ARG >> $FILE |
diff --git a/tests/builtin.at b/tests/builtin.at index 88e24d7..c13b42b 100644 --- a/tests/builtin.at +++ b/tests/builtin.at | |||
@@ -1,5 +1,5 @@ | |||
1 | # This file is part of GNU pies testsuite. -*- Autotest -*- | 1 | # This file is part of GNU pies testsuite. -*- autotest -*- |
2 | # Copyright (C) 2016-2020 Sergey Poznyakoff | 2 | # Copyright (C) 2016-2023 Sergey Poznyakoff |
3 | # | 3 | # |
4 | # GNU pies is free software; you can redistribute it and/or modify | 4 | # GNU pies is free software; you can redistribute it and/or modify |
5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
@@ -40,13 +40,13 @@ component controller { | |||
40 | command "nt -i input -o output $PIES_TEST_INET_SOCKET"; | 40 | command "nt -i input -o output $PIES_TEST_INET_SOCKET"; |
41 | return-code * { | 41 | return-code * { |
42 | action disable; | 42 | action disable; |
43 | exec "piesctl --url '$PIES_CTLSOCK' --no-netrc shutdown"; | 43 | exec "piesctl --config-file=/dev/null --url '$PIES_CTLSOCK' --config-file=/dev/null --no-netrc shutdown"; |
44 | } | 44 | } |
45 | } | 45 | } |
46 | _EOT | 46 | _EOT |
47 | set -e | 47 | set -e |
48 | to 10 \ | 48 | to 10 \ |
49 | pies --foreground --stderr \ | 49 | pies --no-preprocessor --foreground --stderr \ |
50 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog | 50 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog |
51 | 51 | ||
52 | cat output m4_if([$1],[qotd],[| tr -d '\r']) | 52 | cat output m4_if([$1],[qotd],[| tr -d '\r']) |
@@ -78,7 +78,7 @@ component controller { | |||
78 | stderr file "$PWD/controller.err"; | 78 | stderr file "$PWD/controller.err"; |
79 | return-code * { | 79 | return-code * { |
80 | action disable; | 80 | action disable; |
81 | exec "echo \$PIES_STATUS > $PWD/status ; piesctl --url '$PIES_CTLSOCK' --no-netrc shutdown"; | 81 | exec "echo \$PIES_STATUS > $PWD/status ; piesctl --url '$PIES_CTLSOCK' --config-file=/dev/null --no-netrc shutdown"; |
82 | } | 82 | } |
83 | } | 83 | } |
84 | _EOT | 84 | _EOT |
@@ -86,7 +86,7 @@ TZ=0 | |||
86 | export TZ | 86 | export TZ |
87 | set -e | 87 | set -e |
88 | to 10 \ | 88 | to 10 \ |
89 | pies --foreground --stderr \ | 89 | pies --no-preprocessor --foreground --stderr \ |
90 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog | 90 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog |
91 | 91 | ||
92 | if test -s in.err; then | 92 | if test -s in.err; then |
@@ -166,14 +166,14 @@ component test { | |||
166 | stderr file "$PWD/test.err"; | 166 | stderr file "$PWD/test.err"; |
167 | return-code * { | 167 | return-code * { |
168 | action disable; | 168 | action disable; |
169 | exec "piesctl --no-netrc --url=$PIES_CTLSOCK shutdown"; | 169 | exec "piesctl --config-file=/dev/null --no-netrc --url=$PIES_CTLSOCK shutdown"; |
170 | } | 170 | } |
171 | } | 171 | } |
172 | _EOT | 172 | _EOT |
173 | 173 | ||
174 | set -e | 174 | set -e |
175 | to 10 \ | 175 | to 10 \ |
176 | pies --foreground --stderr \ | 176 | pies --no-preprocessor --foreground --stderr \ |
177 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog | 177 | --config-file control.conf --config-file pies.conf --debug 1 2>errlog |
178 | 178 | ||
179 | for err in one.err two.err test.err | 179 | for err in one.err two.err test.err |
diff --git a/tests/chargen.c b/tests/chargen.c index 59aa0d8..5f5a170 100644 --- a/tests/chargen.c +++ b/tests/chargen.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of GNU Pies testsuite. | 1 | /* This file is part of GNU Pies testsuite. |
2 | Copyright (C) 2019-2020 Sergey Poznyakoff | 2 | Copyright (C) 2019-2023 Sergey Poznyakoff |
3 | 3 | ||
4 | GNU Pies is free software; you can redistribute it and/or modify | 4 | GNU Pies is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
diff --git a/tests/control.at b/tests/control.at index 5171862..6027817 100644 --- a/tests/control.at +++ b/tests/control.at | |||
@@ -1,5 +1,5 @@ | |||
1 | # This file is part of GNU pies testsuite. -*- Autotest -*- | 1 |