#3095: Procps-ng-3.3.6
-------------------------+--------------------------------------------------
Reporter: gespinasse | Owner: lfs-book@…
Type: enhancement | Status: new
Priority: normal | Milestone: 7.3
Component: Book | Version: SVN
Severity: normal | Keywords:
-------------------------+--------------------------------------------------
Comment(by bdubbs@…):
I think I've figured out the failures. The script has:
{{{
set pmap_initname "1:\\s+\\S+\[^\\r\]+\\s+"
...
set test "pmap X with unreachable process"
spawn $pmap -X 1
expect_pass $test "$pmap_initname\$"
}}}
where the expect_pass is a function defined in the unix.exp script:
{{{
proc expect_pass { testname reg } {
expect {
-re "$reg" { pass "$testname" }
default { fail "$testname" }
timeout { fail "$testname" }
}
}
}}}
The "$pmap_initname\$" maps to:
{{{
1:
one or more spaces
one or more non-spaces
one or more anything except return, \r, character
one or more spaces
end-of-line
}}}
The spawn command is producing return characters, \r, as end-of-line, but
I think the regex is expecting a line feed (unix newline, \n) at the end
of the line.
Changing "$pmap_initname\$" to "$pmap_initname\r" makes the test pass.
Just removing the \$ in this string also works.
sed -i -e 's/pmap_initname\\\$/pmap_initname/'
testsuite/pmap.test/pmap.exp
Yes, that's three backslashes, \\\$.
Using the sed to remove 'which', I now get:
{{{
# DEJAGNU=global-conf.exp runtestWARNING: No tool specified
Test Run By root on Sun Jan 20 00:05:18 2013
Native configuration is x86_64-unknown-linux-gnu
=== tests ===
Schedule of variations:
unix
Running target unix
Using /tools/share/dejagnu/baseboards/unix.exp as board description file
for target.
Using /tools/share/dejagnu/config/unix.exp as generic interface file for
target.
Using ./config/unix.exp as tool-and-target-specific interface file.
Running ./free.test/free.exp ...
Running ./kill.test/kill.exp ...
Running ./lib.test/fileutils.exp ...
Running ./lib.test/strutils.exp ...
Running ./pgrep.test/pgrep.exp ...
Running ./pkill.test/pkill.exp ...
Running ./pmap.test/pmap.exp ...
Running ./ps.test/ps_output.exp ...
Running ./ps.test/ps_personality.exp ...
Running ./ps.test/ps_sched_batch.exp ...
Running ./pwdx.test/pwdx.exp ...
Running ./slabtop.test/slabtop.exp ...
Running ./sysctl.test/sysctl_read.exp ...
Running ./uptime.test/uptime.exp ...
Running ./vmstat.test/vmstat.exp ...
Running ./w.test/w.exp ...
=== Summary ===
# of expected passes 100
# of untested testcases 20
}}}
18 of the untested testcases are in pkill.exp and seem to be placeholders.
The same for pgrep.exp. The untested case in ps seems to be wrong and is
tested OK.
sed -i -e "s/untested/#untested/" testsuite/ps.test/ps_sched_batch.exp
--
Ticket URL: <http://wiki.linuxfromscratch.org/lfs/ticket/3095#comment:17>
LFS Trac <http://wiki.linuxfromscratch.org/lfs/>
Linux From Scratch: Your Distro, Your Rules.
--
http://linuxfromscratch.org/mailman/listinfo/lfs-book
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page