From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5237 invoked from network); 22 Aug 2001 15:47:49 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 22 Aug 2001 15:47:49 -0000 Received: (qmail 5397 invoked by alias); 22 Aug 2001 15:47:35 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 15676 Received: (qmail 5380 invoked from network); 22 Aug 2001 15:47:32 -0000 From: Bart Schaefer Message-Id: <1010822154655.ZM23919@candle.brasslantern.com> Date: Wed, 22 Aug 2001 15:46:55 +0000 X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-workers@sunsite.dk Subject: PATCH: Assorted minor test tweaks MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii I've had these sitting around and wanted to get them committed. Mostly they're whitespace changes in the %prep sections to get the test to exit sooner if something goes horribly wrong. However, there's also a work- around for the "root can read anything" test failure in CO2cond, and a test for `typeset -ft'. --- ../zsh-forge/current/Test/A01grammar.ztst Mon Jul 9 12:10:50 2001 +++ ./Test/A01grammar.ztst Sun Aug 12 12:28:03 2001 @@ -5,6 +5,7 @@ %prep mkdir basic.tmp && cd basic.tmp + touch foo bar %test diff -x CVS -ru ../zsh-forge/current/Test/A05execution.ztst ./Test/A05execution.ztst --- ../zsh-forge/current/Test/A05execution.ztst Mon Jul 9 10:41:34 2001 +++ ./Test/A05execution.ztst Sun Aug 12 12:28:03 2001 @@ -7,7 +7,9 @@ cd command.tmp print '#!/bin/sh\necho This is top' >tstcmd + print '#!/bin/sh\necho This is dir1' >dir1/tstcmd + print '#!/bin/sh\necho This is dir2' >dir2/tstcmd chmod 755 tstcmd dir1/tstcmd dir2/tstcmd diff -x CVS -ru ../zsh-forge/current/Test/C02cond.ztst ./Test/C02cond.ztst --- ../zsh-forge/current/Test/C02cond.ztst Sat Jun 9 11:09:07 2001 +++ ./Test/C02cond.ztst Sun Aug 12 12:52:11 2001 @@ -12,10 +12,12 @@ touch zerolength chgrp $EGID zerolength + print 'Garbuglio' >nonzerolength mkdir modish chgrp $EGID modish + chmod g+xs modish chmod u+s modish chmod +t modish @@ -85,7 +87,12 @@ fi 0dD:-p cond - [[ -r zerolength && ! -r unmodish ]] + if (( EUID == 0 )); then + print -u8 'Warning: Not testing [[ ! -r file ]] (root reads anything)' + [[ -r zerolength && -r unmodish ]] + else + [[ -r zerolength && ! -r unmodish ]] + fi 0:-r cond [[ -s nonzerolength && ! -s zerolength ]] diff -x CVS -ru ../zsh-forge/current/Test/D04parameter.ztst ./Test/D04parameter.ztst --- ../zsh-forge/current/Test/D04parameter.ztst Mon Jul 9 12:10:51 2001 +++ ./Test/D04parameter.ztst Sun Aug 12 12:28:02 2001 @@ -3,7 +3,9 @@ %prep mkdir parameter.tmp + cd parameter.tmp + touch boringfile evenmoreboringfile %test diff -x CVS -ru ../zsh-forge/current/Test/E01options.ztst ./Test/E01options.ztst --- ../zsh-forge/current/Test/E01options.ztst Thu Jul 26 09:40:19 2001 +++ ./Test/E01options.ztst Sun Aug 12 12:28:02 2001 @@ -82,8 +82,11 @@ %prep mkdir options.tmp && cd options.tmp + mkdir tmpcd + touch tmpfile1 tmpfile2 + mydir=$PWD mydirt=`print -P %~` catpath=$(which cat) diff -x CVS -ru ../zsh-forge/current/Test/E02xtrace.ztst ./Test/E02xtrace.ztst --- ../zsh-forge/current/Test/E02xtrace.ztst Mon Jul 9 12:10:51 2001 +++ ./Test/E02xtrace.ztst Sun Aug 12 20:20:26 2001 @@ -2,6 +2,7 @@ %prep mkdir xtrace.tmp && cd xtrace.tmp + function xtf { local regression_test_dummy_variable print "$*" @@ -81,3 +82,10 @@ ?+(eval):21> . ./xt.in Tracing: source 2>file ?+./xt.in:1> print Tracing: source 2>file ?+(eval):22> set +x + + typeset -ft xtf + xtf 'Tracing: function' +0: +>Tracing: function +?+xtf:1> local regression_test_dummy_variable +?+xtf:2> print Tracing: function diff -x CVS -ru ../zsh-forge/current/Test/Y01completion.ztst ./Test/Y01completion.ztst --- ../zsh-forge/current/Test/Y01completion.ztst Sun Jun 24 20:03:00 2001 +++ ./Test/Y01completion.ztst Sun Aug 12 12:28:01 2001 @@ -8,10 +8,10 @@ comptestinit -z $ZTST_testdir/../Src/zsh && { - mkdir dir1 - mkdir dir2 - touch file1 - touch file2 + mkdir dir1 && + mkdir dir2 && + touch file1 && + touch file2 } %test diff -x CVS -ru ../zsh-forge/current/Test/Y03arguments.ztst ./Test/Y03arguments.ztst --- ../zsh-forge/current/Test/Y03arguments.ztst Mon Aug 6 09:03:02 2001 +++ ./Test/Y03arguments.ztst Sun Aug 12 12:28:01 2001 @@ -8,8 +8,8 @@ comptestinit -z $ZTST_testdir/../Src/zsh && { - comptesteval 'compdef _tst tst' - tst_arguments () { comptesteval "_tst () { _arguments ${${(@qq)*}} }" } + comptesteval 'compdef _tst tst' + tst_arguments () { comptesteval "_tst () { _arguments ${${(@qq)*}} }" } } %test -- 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