Joachim Wiberg
cec2d5a4db
test: add missing sbin/task.sh to skeleton dist.
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-22 18:21:19 +02:00
Joachim Wiberg
539d215d0e
test: add missing finit.d to skeleton rootfs
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-22 17:51:04 +02:00
Joachim Wiberg
05e6b3e752
test: new test, verify task behavior with conditions
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-21 20:52:34 +02:00
Joachim Wiberg
209e140ddd
test: let Finit's bootmisc plugin create the /var/run symlink
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-10 22:46:15 +02:00
Joachim Wiberg
377c8bce8c
test: fix dist and tenv-root/ regression from refactor
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-09 17:52:48 +02:00
Joachim Wiberg
7f8a96a73e
test: refactor test framework to use a rootfs skeleton
...
Instead of having to create files, and copying them in place for each
test, we move all static test files to a skeleton rootfs. This makes
it a lot easier to get an overview of how things and how they work.
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-08 07:22:33 +02:00
Joachim Wiberg
b4af86255d
test: rename fserv -> serv, more features to be added
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-03 11:55:11 +02:00
Joachim Wiberg
ec17f0aa23
test: add new test to dist, fixes CI build
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-02 12:14:32 +02:00
Joachim Wiberg
6baf2990e8
test: new test to verify support for forking services
...
Issue #223
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-02 12:08:10 +02:00
Joachim Wiberg
6416e2a1a4
test: minor refactor in build system
...
Add Makefile.am in tenv and common for EXTRA_DIST.
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-04-02 12:07:34 +02:00
Joachim Wiberg
6d14ff84d3
test: add missing script helpers to dist archive
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-03-27 15:41:24 +02:00
Joachim Wiberg
4755e5206b
test: new test, verify SysV start/stop daemon support
...
Install start-stop-daemon in test root. Add S01-service.sh, which uses
start-stop-daemon to start service.sh. Modify service.sh to respect
signals, and not exit immediately when sleep exits due to SIGTERM.
Remove PID file in signal callback and make sure to exit OK
The test itself is basically a copy of the start-stop-service.sh test.
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-03-24 22:11:24 +01:00
Jörgen Sigvardsson
beec0ee590
Test case for initctl signal
...
This commit implements a test for the signal feature of initctl. The
existing service used in tests (`common/service.sh`) has been extended
with a signal trap handler. When SIGUSR1 is received, it will write the
string `'USR1'` to `/tmp/usr1.log`. The test will run `initctl signal
service.sh SIGUSR1` and assert that the contents of the file
`/tmp/usr1.log` really is `USR1`.
2022-02-15 12:43:07 +01:00
Joachim Wiberg
c8e1bd0e9a
test: add new kill test to dist
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-02-12 13:37:55 +01:00
Joachim Wiberg
e9c8d3d740
test: verify finit restarts crashing services & registers new PID
...
We extend the service.sh to emulate a well behaving service that creates
and removes its own PID file.
The new test emulates a crash by sending SIGKILL to service.sh. We then
verify that Finit restarts it, and eventually registers the new PID when
the services recreates the PID file.
Issue #226
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2022-02-12 13:30:05 +01:00
Joachim Wiberg
3b5cfc5ecf
test: drop checksef.sh from EXTRA_DIST, generated now
...
Also, silence generation of checkself.sh
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2021-04-09 18:05:02 +02:00
Jacques de Laval
7c45fd451e
test: Remove some redundant exports
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-27 18:27:02 +01:00
Jacques de Laval
7fe1189f7b
test: Move test support files to separate dir and keep tests in /test
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-27 14:50:49 +01:00
Jacques de Laval
2f439194e5
test: Fix testenv-root lingering in build dir
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-26 15:35:07 +01:00
Jacques de Laval
6b7ae50fbb
test: Let Make generate shellcheck test from the list of test sources
...
Not very readable yet, so it needs clean up!
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-26 11:24:12 +01:00
Joachim Wiberg
92c6de2c09
test: tests use .sh extension, for .log/.trs transformation
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2021-02-26 10:13:44 +01:00
Jacques de Laval
ea4fe2045d
test: Add sane default for TESTENV_ROOT; enable easier independent test runs
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-25 17:38:56 +01:00
Jacques de Laval
48b732e53d
test: Let Autoconf generate env vars for tests
...
This simplifies the setup script a lot, and also makes it easier to
run tests independently.
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-25 17:37:24 +01:00
Jacques de Laval
cde580ffce
test: Unify setup-root.sh for make check and make distcheck
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-25 11:18:12 +01:00
Jacques de Laval
1efdbeda16
Merge branch 'wip-tests' into wip-tests-build-refactor
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-24 18:48:26 +01:00
Jacques de Laval
a5ef5f3104
test: Fix make check
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-24 16:01:43 +01:00
Magnus Malm
76b2a846a2
test: Slightly improve names of test directories
...
Signed-off-by: Magnus Malm <magnusmalm@gmail.com >
2021-02-24 14:54:45 +01:00
Jacques de Laval
05901a90aa
test: Fix distcheck
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-23 23:20:39 +01:00
Joachim Wiberg
47dcd1cb8a
test: silence make in-out directory
...
Signed-off-by: Joachim Wiberg <troglobit@gmail.com >
2021-02-23 15:45:21 +01:00
Magnus Malm
25ffc3192f
test: Add two new tests
...
* test_start_stop_service
Test that we can start/stop (via initctl) a service configured in
finit.conf
* test_start_stop_service_sub_config
Test that we can start/stop (via initctl) a service configured in
finit.d/ files
Signed-off-by: Magnus Malm <magnusmalm@gmail.com >
2021-02-23 15:30:42 +01:00
Magnus Malm
b364fd7d6a
test: Add test for dynamically add/remove service in finit.d/ files
...
Signed-off-by: Magnus Malm <magnusmalm@gmail.com >
2021-02-23 11:24:54 +01:00
Magnus Malm
eda9ae4c3e
test: Rename start/stop service test to add/remove dynamic service
...
Signed-off-by: Magnus Malm <magnusmalm@gmail.com >
2021-02-23 11:19:57 +01:00
Jacques de Laval
11841ceb5d
test: Clean up Automake integration of tests
...
Signed-off-by: Jacques de Laval <jacques@de-laval.se >
2021-02-22 22:07:17 +01:00