Some checks will fail due to different locales. For example 1.2 will
become 1,2 so the match fails. Problem reported by Alfredo Esteban
with fix suggested by Mike Frysinger
When ps is not available (like it may happen in a chroot), pgrep.exp and pkill.exp tests fail.
Use just build ps instead.
Signed-off-by: Gilles Espinasse <g.esp@free.fr>
Fix the build where it seems a code fix for Linux was likely untested
on other systems.
Define SCHED_BATCH in test-schedbatch, for systems that don't have it;
the corresponding RH BZ#741090 patch used the magic value 3 in output.c
anyway.
Bug-Debian: http://bugs.debian.org/677055
-x test should have work only in sizeof(KLONG) == 8 case where 3 numbers are printed
In sizeof(KLONG) != 8, only one number and three '-' are printed, so allow '-' character
I am compiling x86 32bits userspace, so I should be in (sizeof(KLONG) != 8) case
Signed-off-by: Gilles Espinasse <g.esp@free.fr>
When the build system is a chroot with no user logged in , all w tests fail because of {1,} match rule for the userline
Allow 0 match replacing {1,} with *
Signed-off-by: Gilles Espinasse <g.esp@free.fr>
The testsuite failed on archlinux which has sleep in /usr/bin/
instead of /bin/ directory. This commit will make expect to use
$PATH to determine where sleep is.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Under certain circumstances, using abort() when either make check
or make distcheck puts ps into an infinite loop around the
function catastrophic_failure() in ps and the C library raise
and abort functions.
Using exit removes this problem and does almost the same thing.
The pwdx check expected error message, which where in use for only
short period of time. The old message was put in place in commit
9d47cb0c38
The vmstat issue was triggered by 'sr0' cdrom device, which gives
following unexpected output. Fix simply ignores partitions which has
zero activity. Besides such partitions probably would not apply as
good candidate of -p option anyway.
$ vmstat -p sr0
Partition was not found
Reported-By: Moritz Muehlenhoff <jmm@debian.org>
Bug-Debian: http://bugs.debian.org/656508
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
The dejagnu tests for slabtop are skipped when "/proc/slabinfo" is
unreadable due to permissions. This commit provides the same check
for vmstat under its -m (slabinfo) option.
Makefile.am testsuite needed to explicitly state the files because while
everything else works, make distcheck fails.
NEWS got updated with the Debian bug number for pgrep -u
There is a race condition between expect script consuming the output
from slabtop. There were a sequences of lines that looked like
^\d+ ... \s*
with the last \s* consuming the first space on the start of the line.
However if the line takes too long to print, then expect stops there and
the space at the start of the subsquent line does not match.
The solution is a \s* at the start ofthe line.
Fix to ./autogen.sh error bellow.
/usr/share/automake-1.11/am/dejagnu.am: DEJATOOL was already defined in condition LINUX, which is included in condition TRUE ...
testsuite/Makefile.am:6: ... `DEJATOOL' previously defined here
Reference: http://www.freelists.org/post/procps/procpsng-331-nearly-there,5
Reported-by: Jim Warner <james.warner@comcast.net>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Makefile will now only test for Linux systems, a work around in the
makefile due to some silly redefine restrictions.
uptime and w now won't error due to being one user logged in, thanks to
Sami for the patch
kill processes by pid test commented out due to false negatives
pwdx process 1 check also commented out due to false negatives
procps works well on Linux, on other arches there are some strange
differences due to their emulation of procfs which is not 100%
Disabling checks for non-linux until that can be sorted out.