Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Test Failures



Peter Stephenson <pws@xxxxxxx> writes:
> Vin Shelton wrote:
>> > } ***************
>> > } *** 1,2 ****
>> > } - 1) one     2) two     3) three   
>> > }   input> input> 
>> > } --- 1 ----
>> > } Was testing: `select' loop
>> 
>> OK, FWIW, I see the failure on both Solaris 5.5 and 5.8 at work, and
>> on my linux box:
>
> Does normal select work?
Normal select works.  At least this script:

    #!/bin/sh
 
    # Execute this script under the Z shell
    [ ! -n "$ZSH_VERSION" ] && exec zsh -f "$0" ${1+"$@"}

    progname=${0:t}

    PROMPT3='Select prompt> '

    select choice in one two three
    do
      case $choice in
      (one|two|three)
        echo You chose $choice
        break
        ;;
      esac
    done

does the expected thing.

> If so, does it non-interactively send messages to stderr?
I'm not sure what you mean here.  When I run the script here is what
gets output to stderr:

    1) one    2) two    3) three  
    Select prompt> 


> Any sign of the missing message appearing on the terminal?
No.  I ran:
  ZTST_verbose=1 make TESTNUM=A01 check >out 2>err

Here is the contents of out:
    cd Test ; make check
    make[1]: Entering directory `/u/shelton2/software/build/SunOS-5.8/zsh-2003-03-31-1145/Test'
    if test -n "/opt/SUNWspro/bin/cc"; then \
      cd .. && DESTDIR= \
      make MODDIR=`pwd`/Test/Modules install.modules > /dev/null; \
    fi
    for f in /u/shelton2/software/src/zsh-2003-03-31-1145/Test/A01*.ztst; do \
      ../Src/zsh +Z -f /u/shelton2/software/src/zsh-2003-03-31-1145/Test/ztst.zsh $f; \
    done
    /u/shelton2/software/src/zsh-2003-03-31-1145/Test/A01grammar.ztst: starting.
    Running test: Basic pipeline handling
    Test successful.
    Running test: Exit status of pipeline with builtins (true)
    Test successful.
    Running test: Exit status of pipeline with builtins (false)
    Test successful.
    Running test: Basic coprocess handling
    Test successful.
    Running test: Basic sublist (i)
    Test successful.
    Running test: Basic sublist (ii)
    Test successful.
    Running test: Basic subshell list with error
    Test successful.
    Running test: Basic current shell list with error
    Test successful.
    Running test: `-' precommand modifier
    Test successful.
    Running test: `noglob' precommand modifier
    Test successful.
    Running test: `exec' precommand modifier
    Test successful.
    Running test: `command' precommand modifier
    Test successful.
    Running test: `builtin' precommand modifier
    Test successful.
    Running test: `if ...' (i)
    Test successful.
    Running test: `if ...' (ii)
    Test successful.
    Running test: `if ...' (iii)
    Test successful.
    Running test: `if ...' (iv)
    Test successful.
    Running test: `for' loop
    Test successful.
    Running test: `for' loop with newline before in keyword
    Test successful.
    Running test: arithmetic `for' loop
    Test successful.
    Running test: enhanced `for' syntax with two loop variables
    Test successful.
    Running test: enhanced `for' syntax with three loop variables
    Test successful.
    Running test: compatibility of enhanced `for' syntax with standard syntax
    Test successful.
    Running test: `while' loop
    Test successful.
    Running test: `until' loop
    Test successful.
    Running test: `repeat' loop
    Test successful.
    Running test: `case', old syntax
    Test successful.
    Running test: `case', new syntax
    Test successful.
    Running test: `case', new syntax, cascaded
    Test successful.
    Running test: `select' loop
    *** /tmp/zsh.ztst.err.5558	Mon Mar 31 16:33:24 2003
    --- /tmp/zsh.ztst.terr.5558	Mon Mar 31 16:33:24 2003
    ***************
    *** 1,2 ****
    ! 1) one     2) two     3) three   
      input> input> 
    --- 1,2 ----
    ! 1) one    2) two    3) three  
      input> input> 
    Test /u/shelton2/software/src/zsh-2003-03-31-1145/Test/A01grammar.ztst failed: error output differs from expected as shown above for:
      PS3="input> "
      select name in one two three; do
        print $name
      done
    Was testing: `select' loop
    /u/shelton2/software/src/zsh-2003-03-31-1145/Test/A01grammar.ztst: test failed.
    rm -rf Modules .zcompdump
    make[1]: Leaving directory `/u/shelton2/software/build/SunOS-5.8/zsh-2003-03-31-1145/Test'

Here is the contents of err:
    mkdir /u/shelton2/software/build/SunOS-5.8/zsh-2003-03-31-1145/Test/Modules
    mkdir /u/shelton2/software/build/SunOS-5.8/zsh-2003-03-31-1145/Test/Modules/zsh
    mkdir /u/shelton2/software/build/SunOS-5.8/zsh-2003-03-31-1145/Test/Modules/zsh/net
    make[1]: [check] Error 1 (ignored)

and nothing was printed on the terminal.  It looks to me that the only
difference is that there are extra spaces in the first line:
'one     ' vs. 'one    ',
'two     ' vs. 'two    ' and
'three   ' vs. 'three  '.


  - Vin



Messages sorted by: Reverse Date, Date, Thread, Author