mirror of
https://github.com/troglobit/finit.git
synced 2026-10-22 11:36:07 +00:00
test: New test: test_start_stop_service
Add a new test that verifies that Finit will: - Start a service that's been added to the config - Stop the service once it's removed from the config The second step is currently failing. Signed-off-by: Jacques de Laval <jacques@de-laval.se>
This commit is contained in:
1 parent
4f82cb8261
commit
4224c2e8fe
7 files changed
+98
-6
No files matched your search
+8
-4
@@ -8,18 +8,22 @@ testroot_bin = $(testroot)/bin
|
||||
binaries = $(testroot_bin)/cat \
|
||||
$(testroot_bin)/date \
|
||||
$(testroot_bin)/echo \
|
||||
$(testroot_bin)/kill \
|
||||
$(testroot_bin)/ls \
|
||||
$(testroot_bin)/mkdir \
|
||||
$(testroot_bin)/mkfifo \
|
||||
$(testroot_bin)/mknod \
|
||||
$(testroot_bin)/mount \
|
||||
$(testroot_bin)/printf \
|
||||
$(testroot_bin)/pgrep \
|
||||
$(testroot_bin)/ps \
|
||||
$(testroot_bin)/rm \
|
||||
$(testroot_bin)/sh \
|
||||
$(testroot_bin)/sleep \
|
||||
$(testroot_bin)/top \
|
||||
$(testroot_bin)/touch
|
||||
dirs = $(testroot)/dev \
|
||||
$(testroot)/etc \
|
||||
$(testroot)/lib \
|
||||
$(testroot)/proc \
|
||||
$(testroot)/sbin \
|
||||
@@ -45,8 +49,8 @@ $(testroot_bin)/%: $(testroot_bin)/$(busybox-bin)
|
||||
cd $(testroot_bin); \
|
||||
ln -s $(busybox-bin) $(notdir $@)
|
||||
|
||||
$(testroot_bin)/testwrapper.sh:
|
||||
cp testwrapper.sh $@
|
||||
$(testroot_bin)/chrootsetup.sh: chrootsetup.sh
|
||||
cp $< $@
|
||||
|
||||
$(testroot)/sbin/finit: ../src/finit $(testroot)/lib/ld-musl-x86_64.so.1 $(testroot)/usr/local/lib/libite.so.5 $(testroot)/usr/local/lib/libuev.so.2
|
||||
cp $< $@
|
||||
@@ -61,8 +65,8 @@ $(testroot)/usr/local/lib/libuev.so.2:
|
||||
cp test_root.backup/usr/local/lib/libuev.so.2 $@
|
||||
|
||||
.PHONY: test
|
||||
test: $(binaries) $(testroot_bin)/testwrapper.sh $(dirs) $(testroot)/sbin/finit
|
||||
./run.sh finit
|
||||
test: $(binaries) $(testroot_bin)/chrootsetup.sh $(dirs) $(testroot)/sbin/finit
|
||||
./runtest.sh ./test_start_stop_service/test.sh
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
||||
Reference in new issue
Block a user