1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2024-06-01 12:56:04 +02:00

Assorted minor test tweaks.

This commit is contained in:
Bart Schaefer 2001-08-22 15:59:27 +00:00
parent 4fe788b092
commit 4ab1fb2bd3
9 changed files with 38 additions and 7 deletions

View File

@ -1,5 +1,13 @@
2001-08-22 Bart Schaefer <schaefer@zsh.org>
* 15676: Test/A01grammar.ztst, Test/A05execution.ztst,
Test/C02cond.ztst, Test/D04parameter.ztst, Test/E01options.ztst,
Test/E02xtrace.ztst, Test/Y01completion.ztst,
Test/Y03arguments.ztst: Tweak %prep sections to exit sooner on
certain failures (by adding blank lines). Other whitespace-only
changes. Avoid [[ ! -r ... ]] test when running as root, as it
always fails in that case. Test `typeset -ft' (function trace).
* 15608: Completion/Zsh/Command/_cd: Don't treat numbers as
cd-able vars.

View File

@ -5,6 +5,7 @@
%prep
mkdir basic.tmp && cd basic.tmp
touch foo bar
%test

View File

@ -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

View File

@ -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 ]]

View File

@ -3,7 +3,9 @@
%prep
mkdir parameter.tmp
cd parameter.tmp
touch boringfile evenmoreboringfile
%test

View File

@ -82,8 +82,11 @@
%prep
mkdir options.tmp && cd options.tmp
mkdir tmpcd
touch tmpfile1 tmpfile2
mydir=$PWD
mydirt=`print -P %~`
catpath=$(which cat)

View File

@ -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

View File

@ -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

View File

@ -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