Expect failures - Chapt 5.12.1

Timothy Legg lfs at timothylegg.com
Tue Feb 16 15:46:34 PST 2010


Hello,

Thanks for the wonderful advice last time.

I have moved along.  On chapter 5.12.1 where I 'make test', I get back 7
failures, output is at end of this message.

Tis is similar to two occurances in previous threads, but I am not
familiar enough with these tools for the information to be of much use.
Any ideas?

http://www.linuxfromscratch.org/pipermail/lfs-support/2003-October/019968.html
http://www.linuxfromscratch.org/pipermail/lfs-support/2003-May/017409.html



My results:

lfs at engineering:/mnt/lfs/sources/expect-5.43$ make test
rm -f .tmp
echo "set objdir" `pwd` > .tmp
if [ "." = "." ] ; then \
           echo "set srcdir" `pwd` >> .tmp ; \
        else echo "set srcdir" . >> .tmp ; fi
echo "cd \${srcdir}/tests" >> .tmp
echo "source all.tcl" >> .tmp
rootme=`pwd`; export rootme; \
        srcdir=. ; export srcdir ; \
        if [ -f ./expect ] ; then  \
           TCL_LIBRARY=/tools/includelibrary ; \
           export TCL_LIBRARY ; fi ; \
        LD_LIBRARY_PATH=.:/tools/lib:/tools/lib:$LD_LIBRARY_PATH ./expect
-f .tmp
cat.test
expect.test


==== expect-1.4 glob pattern FAILED
==== Contents of test case:

    expect "*"
    exp_send "a\r"

    set timeout 10
    set x 0
    expect "a" {set x 1}
    set x

---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: expect: spawn id exp4 not open
    while executing
"expect "*""
    ("uplevel" body line 2)
    invoked from within
"uplevel 1 $script"
---- errorCode: NONE
==== expect-1.4 FAILED



==== expect-1.5 glob pattern buffering FAILED
==== Contents of test case:

    expect "*"
    exp_send "a\r"

    set timeout 10
    set x 0
    expect "*" {set x 1}
    set x

---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: expect: spawn id exp4 not open
    while executing
"expect "*""
    ("uplevel" body line 2)
    invoked from within
"uplevel 1 $script"
---- errorCode: NONE
==== expect-1.5 FAILED



==== expect-1.6 glob buffer FAILED
==== Contents of test case:

    expect "*"
    exp_send "philosophic\r"

    set timeout 10
    set x 0
    expect "hi"
    set x [string match *phi $expect_out(buffer)]

---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: expect: spawn id exp4 not open
    while executing
"expect "*""
    ("uplevel" body line 2)
    invoked from within
"uplevel 1 $script"
---- errorCode: NONE
==== expect-1.6 FAILED



==== expect-1.7 glob string FAILED
==== Contents of test case:

    expect "*"
    exp_send "philosophic\r"

    set timeout 10
    set x 0
    expect "hi"
    set expect_out(0,string)

---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: expect: spawn id exp4 not open
    while executing
"expect "*""
    ("uplevel" body line 2)
    invoked from within
"uplevel 1 $script"
---- errorCode: NONE
==== expect-1.7 FAILED

spawn_id: spawn id exp4 not open
logfile.test
via sendvia send_uservia send_stdoutvia send_ttypid.test
send.test


==== send-1.1 basic send operation FAILED
==== Contents of test case:

    spawn cat
    after 1000
    send "foo\r"
    expect foo
    after 1000
    send "\u0004"
    expect eof
    regexp "\r\nfoo\r\n" $expect_out(buffer)

---- Result was:
0
---- Result should have been (exact matching):
1
==== send-1.1 FAILED



==== send-1.2 send null FAILED
==== Contents of test case:

    spawn od -c
    send "a\u0000b\r"
    after 1000
    send \u0004
    expect eof
    regexp "a  \\\\0   b" $expect_out(buffer)

---- Result was:
0
---- Result should have been (exact matching):
1
==== send-1.2 FAILED

spawn.test


==== spawn-1.4 spawn open file FAILED
==== Contents of test case:

        set x 0
        set y 0

        set file [open /tmp/[pid] w]
        puts $file "testing expect's spawn -open"
        exp_close $file
        set pid [exp_spawn -open [open /tmp/[pid]]]
        expect "testing expect's spawn -open" {set x 1}
        expect eof {set y 1}
        exec rm /tmp/[pid]
        exp_wait
        list $x $y $pid

---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
---- errorInfo: child killed: segmentation violation
    while executing
"exec rm /tmp/[pid]"
    ("uplevel" body line 11)
    invoked from within
"uplevel 1 $script"
---- errorCode: CHILDKILLED 13557 SIGSEGV {segmentation violation}
==== spawn-1.4 FAILED

stty.test
all.tcl:        Total        22        Passed        15        Skipped    
   0        Failed        7
Sourced 0 Test Files.
Files with failing tests: logfile.test send.test spawn.test
rm -f .tmp
lfs at engineering:/mnt/lfs/sources/expect-5.43$



Tim Legg






More information about the lfs-support mailing list