summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>2021-02-25 20:27:30 -0500
committerDaniel Kahn Gillmor <dkg@fifthhorseman.net>2021-02-25 23:17:25 -0500
commit7b1d0958b5e2db82fcc8a5da9de9df3c72b26975 (patch)
treed24b11e3a1231e285919fa25a2d01d24899e825f /test
parent17522c5ba124c5941e2cd3832a68722d64c6bf4b (diff)
downloadlibfaketime-7b1d0958b5e2db82fcc8a5da9de9df3c72b26975.tar.gz
Drop duplicate library constructor preload tests
These tests are already taken care of with the snippet-driven library constructor tests.
Diffstat (limited to 'test')
-rw-r--r--test/Makefile4
-rwxr-xr-xtest/pidtest.sh7
-rwxr-xr-xtest/randomtest.sh9
3 files changed, 2 insertions, 18 deletions
diff --git a/test/Makefile b/test/Makefile
index aed85a5..6a568e2 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -27,10 +27,10 @@ functest:
%_test: %_test.c
${CC} -o $@ ${CFLAGS} $<
-randomtest: getrandom_test use_lib_getrandom libgetrandom.so repeat_random getentropy_test
+randomtest: getrandom_test repeat_random getentropy_test
./randomtest.sh
-getpidtest: use_lib_getpid libgetpid.so
+getpidtest:
./pidtest.sh
syscalltest: syscall_test
diff --git a/test/pidtest.sh b/test/pidtest.sh
index 83e0771..617bad8 100755
--- a/test/pidtest.sh
+++ b/test/pidtest.sh
@@ -17,10 +17,3 @@ if [ $output != 13 ]; then
printf >&2 'Failed to enforce a rigid response to getpid()\n'
exit 2
fi
-
-printf 'testing shared object with getpid() in library constructor\n'
-LD_LIBRARY_PATH=. ./use_lib_getpid
-printf 'now with LD_PRELOAD and FAKETIME_FAKEPID\n'
-FAKETIME_FAKEPID=25 LD_PRELOAD="$FTPL" LD_LIBRARY_PATH=. ./use_lib_getpid
-printf 'now with LD_PRELOAD without FAKETIME_FAKEPID\n'
-LD_PRELOAD="$FTPL" LD_LIBRARY_PATH=. ./use_lib_getpid
diff --git a/test/randomtest.sh b/test/randomtest.sh
index 1ba86e3..052510b 100755
--- a/test/randomtest.sh
+++ b/test/randomtest.sh
@@ -34,15 +34,6 @@ for iface in getrandom getentropy; do
rm -f "${iface}.alone" "${iface}.preload" "${iface}.preload.seed0" "${iface}.preload.seed1" "${iface}.preload.seed2"
done
-printf 'testing shared object with getrandom() in library constructor\n'
-LD_LIBRARY_PATH=. ./use_lib_getrandom
-printf 'now with LD_PRELOAD and FAKERANDOM_SEED\n'
-FAKERANDOM_SEED=0x0000000000000000 LD_PRELOAD="$FTPL" LD_LIBRARY_PATH=. ./use_lib_getrandom
-# this demonstrates the crasher from https://github.com/wolfcw/libfaketime/issues/295
-printf 'now with LD_PRELOAD without FAKERANDOM_SEED\n'
-LD_PRELOAD="$FTPL" LD_LIBRARY_PATH=. ./use_lib_getrandom
-
-
FAKERANDOM_SEED=0xDEADBEEFDEADBEEF LD_PRELOAD="$FTPL" ./repeat_random 3 5 > repeat3x5
FAKERANDOM_SEED=0xDEADBEEFDEADBEEF LD_PRELOAD="$FTPL" ./repeat_random 5 3 > repeat5x3