tests: cleanup islocal test
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
cbbd518594
commit
c293a7e8ae
|
@ -1,4 +1,4 @@
|
|||
islocal_test
|
||||
test_islocal
|
||||
chfn
|
||||
chsh
|
||||
login
|
||||
|
|
|
@ -65,7 +65,6 @@ install-exec-hook::
|
|||
|
||||
endif
|
||||
|
||||
noinst_PROGRAMS = islocal_test
|
||||
islocal_test_SOURCES = islocal.c
|
||||
islocal_test_CPPFLAGS = -DMAIN_TEST_ISLOCAL $(AM_CPPFLAGS)
|
||||
|
||||
noinst_PROGRAMS = test_islocal
|
||||
test_islocal_SOURCES = islocal.c
|
||||
test_islocal_CPPFLAGS = -DTEST_PROGRAM $(AM_CPPFLAGS)
|
||||
|
|
|
@ -92,12 +92,12 @@ is_local(const char *user)
|
|||
}
|
||||
}
|
||||
|
||||
#if MAIN_TEST_ISLOCAL
|
||||
#ifdef TEST_PROGRAM
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
if (argc < 2) {
|
||||
fprintf(stderr, "No test passwd file was specified.\n");
|
||||
if (argc <= 2) {
|
||||
fprintf(stderr, "usage: %s <passwdfile> <username> [...]\n", argv[0]);
|
||||
return 1;
|
||||
} else {
|
||||
int i;
|
||||
|
|
|
@ -24,6 +24,8 @@ TS_HELPER_LIBMOUNT_UPDATE="$top_builddir/libmount/src/test_tab_update"
|
|||
TS_HELPER_LIBMOUNT_CONTEXT="$top_builddir/libmount/src/test_context"
|
||||
TS_HELPER_LIBMOUNT_TABDIFF="$top_builddir/libmount/src/test_tab_diff"
|
||||
|
||||
TS_HELPER_ISLOCAL="$top_builddir/login-utils/test_islocal"
|
||||
|
||||
# TODO: use partx
|
||||
TS_HELPER_PARTITIONS="$top_builddir/libblkid/samples/partitions"
|
||||
|
||||
|
@ -55,7 +57,6 @@ TS_CMD_LOOK=${TS_CMD_LOOK-"$top_builddir/misc-utils/look"}
|
|||
TS_CMD_CAL=${TS_CMD_CAL-"$top_builddir/misc-utils/cal"}
|
||||
TS_CMD_SCRIPT=${TS_CMD_SCRIPT-"$top_builddir/term-utils/script"}
|
||||
|
||||
TS_CMD_ISLOCAL=${TS_CMD_ISLOCAL-"$top_builddir/login-utils/islocal_test"}
|
||||
|
||||
TS_CMD_HWCLOCK=${TS_CMD_HWCLOCK-"$top_builddir/hwclock/hwclock"}
|
||||
TS_CMD_LSCPU=${TS_CMD_LSCPU-"$top_builddir/sys-utils/lscpu"}
|
||||
|
|
|
@ -21,7 +21,7 @@ TS_DESC="islocal"
|
|||
. $TS_TOPDIR/functions.sh
|
||||
ts_init "$*"
|
||||
|
||||
$TS_CMD_ISLOCAL "$TS_SELF/islocal.data" root nobody "" youngman youngman2 \
|
||||
$TS_HELPER_ISLOCAL "$TS_SELF/islocal.data" root nobody "" youngman youngman2 \
|
||||
abcdefghx nobo long rot al malformed \
|
||||
nonl znobody >> $TS_OUTPUT
|
||||
ts_finalize
|
||||
|
|
Loading…
Reference in New Issue