From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24505 invoked from network); 24 Mar 2001 23:59:10 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 24 Mar 2001 23:59:10 -0000 Received: (qmail 16882 invoked by alias); 24 Mar 2001 23:59:04 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 13744 Received: (qmail 16870 invoked from network); 24 Mar 2001 23:59:04 -0000 From: "Bart Schaefer" Message-Id: <1010324235714.ZM31898@candle.brasslantern.com> Date: Sat, 24 Mar 2001 23:57:14 +0000 X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-workers@sunsite.dk Subject: PATCH: More comments in ztst files MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii General remark -- in several of the ztst files, there are comments about not being able to test various interactive operations, such as `select' loops (always read from terminal) or `[[ -t 0 ]]'. We should lump these into a later test and use the zpty module the way we do for completion. I haven't actually done this. In 04redirect.ztst: # Following two tests have to be separated since in # print bar >foo >bar && print "$( $bar turns this into $$, which doesn't strike me as correct. Where "this" is ${(...)${bar}}. We've long since decided that's correct; in fact, zsh now prints "bad substitution" for ${$bar}. That's it. The other two hunks remove a comment from 01grammar that I meant to remove in my last patch for it, and add to ztst.zsh a line to print when the tests begin as well as when they end, which is helpful to my sanity. Index: Test/01grammar.ztst =================================================================== --- Test/01grammar.ztst 2001/03/24 22:19:21 1.5 +++ Test/01grammar.ztst 2001/03/24 22:19:51 @@ -289,8 +289,6 @@ >Hip hip hooray >Hip hip hooray -# Why doesn't this one work here? It works from the command line -# or with zsh -fc. case bravo { (alpha) print schmalpha ;; Index: Test/10prompt.ztst =================================================================== --- Test/10prompt.ztst 2000/02/11 06:59:21 1.2 +++ Test/10prompt.ztst 2001/03/24 23:16:25 @@ -6,10 +6,9 @@ %test -# 'mydir=$PWD; hash -d mydir; print -P %~' doesn't seem to abbreviate -# to ~mydir in a non-interactive shell. Is this correct? - + hash -d mydir=$mydir print -P ' %%%): %) + %%~: %~ %%d: %d %%1/: %1/ %%h: %h @@ -23,6 +22,7 @@ ' 0q:Basic prompt escapes as shown. > %): ) +> %~: ~mydir > %d: $mydir > %1/: ${mydir:t} > %h: 0 Index: Test/13parameter.ztst =================================================================== --- Test/13parameter.ztst 2000/05/03 10:44:46 1.2 +++ Test/13parameter.ztst 2001/03/24 23:38:47 @@ -157,7 +157,7 @@ >IFonce bitten twice shyTHEN >IFonceTHEN IFbittenTHEN IFtwiceTHEN IFshyTHEN - # WHY DO I NEED TO QUOTE ${array} HERE????? + # Quote ${array} here because {...,...} doesn't like unquoted spaces. print IF{"${array}",THEN}ELSE print IF{${^array},THEN}ELSE 0:combined ${^...} and {...,...} @@ -221,8 +221,6 @@ 0:${(P)...} >I'm nearly out of my mind with tedium - # it doesn't *say* these are case-insensitive without i... - # I think this is a bug. foo=(I could be watching that programme I recorded) print ${(o)foo} print ${(oi)foo} @@ -466,7 +464,7 @@ >b* e* >boringfile evenmoreboringfile - # ${bar} -> $bar turns this into $$, which doesn't strike me as correct. + # ${bar} -> $bar here would yield "bad substitution". bar=confinement print ${(el.20..X.)${bar}} 0:Rule 11: Padding Index: Test/ztst.zsh =================================================================== --- Test/ztst.zsh 2000/06/07 16:56:19 1.11 +++ Test/ztst.zsh 2001/03/23 18:31:05 @@ -336,6 +336,8 @@ typeset -A ZTST_sects ZTST_sects=(prep 0 test 0 clean 0) +print "$ZTST_testname: starting." + # Now go through all the different sections until the end. while ZTST_getsect; do case $ZTST_cursect in -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net