[Bash-completion-devel] Test suite failures/questions

Ville Skyttä ville.skytta at iki.fi
Mon Nov 9 20:55:13 UTC 2009


On Monday 09 November 2009, Freddy Vulto wrote:
> On 12:08, Ville Skyttä wrote:
> > 1) ./runCompletion (alone, or with $something.exp) always prints out:
> > ----
> > ERROR Unexpected output from bash command "bash --rcfile config/bashrc":
> > ----
> > By adding some send_user's to assert_bash_exec I found that the
> > "unexpected" output, $results, is empty when printed, but its string
> > length is 8.  Huh?
> 
> I'm having the testsuite running every night on a Debian machine without
> errors now.  Maybe `$results' is whitespace on your machine/distro?
> What do you get when you invoke test-bash manually?  This is what I get:
> 
>     $ bash-completion.git/test> bash --rcfile config/bashrc
>     /@
> 
> with the cursor right after the `@'.  Can you try appending a `!' to
>  `assert_bash_exec' in test/lib/library.exp so it looks like this:
> 
>    send_user "ERROR Unexpected output from bash command
>    \"$title\":\n$results!"
> 
> and show where the exclamation mark appears in the output, just to check
> if `$results' is whitespace?

I tried to explain that I had already verified that it isn't, but I did it 
again with the same results: nothing seen, but 8 characters long.  Then I 
looked at log/completion.log and saw this:

ESC[?1034h/@ERROR Unexpected output from bash command "bash --rcfile 
config/bashrc":
ESC[?1034h!echo $?

...which by some googling leads to for example:
http://bugs.gentoo.org/246091
http://reinout.vanrees.org/weblog/2009/08/14/readline-invisible-character-
hack.html

...and indeed, if I set TERM=dummy or TERM=linux or TERM=vt100 in the 
environment, the error goes away.  Originally it was TERM=xterm, this is in a 
KDE konsole window.  So maybe a readline issue?  Do you think the attached 
patch would be ok?

> > 2) finger's "Tab should complete partial hostname" test fails.  It's just
> > the test - as far as I can tell, the actual completion works fine when I
> > run it in a shell.
> 
> I've done some fixes to the test suite some days ago.  Does the `finger'
> test still fail?  If so, can you provide the line containing FAIL (and a
> few lines before that) of ./test/log/completion.log?

Sure, here goes.

^C
/@finger test at l
test at localhost                test at localhost4               
test at localhost4.localdomain4  test at localhost6
test at localhost6.localdomain6  test at localhost.localdomain
/@finger test at localhostFAIL: Tab should complete partial hostname
^C

> > 3) All xhost completion tests (except unmodified env) fail.  Again, the
> > completions seem to work just fine when run in a shell.
> 
> Same as above.  Can you provide the FAILing line from
> ./test/log/completion.log?

The partial hostname ones are essentially the same as in the finger case 
above.  For example:

^C
/@xhost +l
+localhost                +localhost4               +localhost4.localdomain4  
+localhost6               +localhost6.localdomain6
+localhost.localdomain
/@xhost +localhostFAIL: xhost +l should show completions
^C

For the other non-partial hostname ones, I see a lot of completions offered, 
and they look ok.  For example:

^C
/@xhost -
[...lots of hostname completions prefixed with "-" snipped...]
/@xhost -FAIL: Tab should complete hostnames prefixed with -
^C
-------------- next part --------------
A non-text attachment was scrubbed...
Name: config-term.patch
Type: text/x-patch
Size: 495 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20091109/ae81e516/attachment.bin>


More information about the Bash-completion-devel mailing list