* bug#22420: Zsh test failure
@ 2016-01-21 2:21 Leo Famulari
2016-01-21 21:02 ` Ludovic Courtès
` (2 more replies)
0 siblings, 3 replies; 14+ messages in thread
From: Leo Famulari @ 2016-01-21 2:21 UTC (permalink / raw)
To: 22420
Zsh fails to build due to a test failure on my system (x86_64).
The test suite does not report where the failure occurs but I believe it
is in section 'Test/B02typeset.ztst' as a result of patch-shebang
failing to find a binary interpreter for 'Test/ztst.zsh':
patch-shebang: ./Test/ztst.zsh: warning: no binary for interpreter `zsh' found in $PATH
I wonder if this means that the file is being interpreted by Bash, or
maybe the 'sh' mode of Bash.
At the conclusion of the test suite:
**************************************
44 successful test scripts, 1 failure, 0 skipped
**************************************
Makefile:189: recipe for target 'check' failed
make[1]: *** [check] Error 1
make[1]: Leaving directory '/tmp/guix-build-zsh-5.1.1.drv-0/zsh-5.1.1/Test'
Makefile:265: recipe for target 'check' failed
make: *** [check] Error 2
phase `check' failed after 30.2 seconds
Here is the verbose output of the test section B02, up to where section
B03 begins. I created the verbose output by setting the make-flag
"ZTST_verbose=2".
Normally, before a new section begins, the previous section reports its
success. That does not happen in this case:
./B02typeset.ztst: starting.
ZTST_getsect: read section name: prep
ZTST_getchunk: read code chunk:
mkdir typeset.tmp && cd typeset.tmp
ZTST_execchunk: status 0
ZTST_getchunk: read code chunk:
setopt noglob
ZTST_execchunk: status 0
ZTST_getchunk: read code chunk:
scalar=scalar
array=(a r r a y)
ZTST_execchunk: status 0
ZTST_getchunk: read code chunk:
scope00() {
typeset scalar
scalar=local
typeset -a array
array=(l o c a l)
print $scalar $array
}
scope01() {
local scalar
scalar=local
local -a array
array=(l o c a l)
print $scalar $array
}
scope02() {
declare scalar
scalar=local
declare -a array
array=(l o c a l)
print $scalar $array
}
scope10() {
export outer=outer
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope11() {
typeset -x outer=outer
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope12() {
local -x outer=inner
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope13() {
local -xT OUTER outer
outer=(i n n e r)
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $OUTER'
}
ZTST_execchunk: status 0
ZTST_getchunk: read code chunk:
# Bug? `typeset -h' complains that ! # $ * - ? @ are not identifiers.
stress00() {
typeset -h +g -m [[:alpha:]_]*
unset -m [[:alpha:]_]*
typeset +m [[:alpha:]_]*
}
ZTST_execchunk: status 0
ZTST_getchunk: read code chunk:
ZTST_getsect: read section name: test
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset +m scalar array
ZTST_getchunk: read code chunk:
typeset +m scalar array
ZTST_test: examining line:
>scalar
ZTST_getredir: read redir for '>':
scalar
array array
ZTST_test: examining line:
Running test: Report types of parameters with typeset +m
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
scalar
array array
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope00
ZTST_getchunk: read code chunk:
scope00
print $scalar $array
ZTST_test: examining line:
>local l o c a l
ZTST_getredir: read redir for '>':
local l o c a l
scalar a r r a y
ZTST_test: examining line:
Running test: Simple local declarations
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
local l o c a l
scalar a r r a y
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope01
ZTST_getchunk: read code chunk:
scope01
print $scalar $array
ZTST_test: examining line:
>local l o c a l
ZTST_getredir: read redir for '>':
local l o c a l
scalar a r r a y
ZTST_test: examining line:
Running test: Equivalence of local and typeset in functions
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
local l o c a l
scalar a r r a y
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope02
ZTST_getchunk: read code chunk:
scope02
print $scalar $array
ZTST_test: examining line:
>local l o c a l
ZTST_getredir: read redir for '>':
local l o c a l
scalar a r r a y
ZTST_test: examining line:
Running test: Basic equivalence of declare and typeset
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
local l o c a l
scalar a r r a y
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
declare +m scalar
ZTST_getchunk: read code chunk:
declare +m scalar
ZTST_test: examining line:
>scalar
ZTST_getredir: read redir for '>':
scalar
ZTST_test: examining line:
Running test: declare previously lacked -m/+m options
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
scalar
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope10
ZTST_getchunk: read code chunk:
scope10
print $outer
ZTST_test: examining line:
>outer
ZTST_getredir: read redir for '>':
outer
outer
ZTST_test: examining line:
Running test: Global export
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
outer
outer
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope11
ZTST_getchunk: read code chunk:
scope11
print $outer
ZTST_test: examining line:
>outer
ZTST_getredir: read redir for '>':
outer
outer
ZTST_test: examining line:
Running test: Equivalence of export and typeset -x
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
outer
outer
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
scope12
ZTST_getchunk: read code chunk:
scope12
print $outer
ZTST_test: examining line:
>inner
ZTST_getredir: read redir for '>':
inner
outer
ZTST_test: examining line:
Running test: Local export
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
inner
outer
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
float f=3.14159
ZTST_getchunk: read code chunk:
float f=3.14159
typeset +m f
float -E3 f
print $f
float -F f
print $f
ZTST_test: examining line:
>float local f
ZTST_getredir: read redir for '>':
float local f
3.14e+00
3.142
ZTST_test: examining line:
Running test: Floating point, adding a precision, and fixed point
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
float local f
3.14e+00
3.142
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
integer i=3.141
ZTST_getchunk: read code chunk:
integer i=3.141
typeset +m i
integer -i2 i
print $i
ZTST_test: examining line:
>integer local i
ZTST_getredir: read redir for '>':
integer local i
2#11
ZTST_test: examining line:
Running test: Integer and changing the base
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
integer local i
2#11
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
float -E3 f=3.141
ZTST_getchunk: read code chunk:
float -E3 f=3.141
typeset +m f
integer -i2 f
typeset +m f
print $f
ZTST_test: examining line:
>float local f
ZTST_getredir: read redir for '>':
float local f
integer 2 local f
2#11
ZTST_test: examining line:
Running test: Conversion of floating point to integer
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
float local f
integer 2 local f
2#11
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -f
ZTST_getchunk: read code chunk:
typeset -f
ZTST_test: examining line:
>$(functions)
ZTST_getredir: read redir for '>':
$(functions)
ZTST_test: examining line:
Running test: Equivalence of functions and typeset -f
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
ZTST_cleanup () {
cd $ZTST_testdir
rm -rf $ZTST_testdir/dummy.tmp $ZTST_testdir/*.tmp(N) ${TMPPREFIX}.ztst*$$(N)
}
ZTST_diff () {
emulate -L zsh
setopt extendedglob
local diff_out
integer diff_pat diff_ret
case $1 in
(p) diff_pat=1 ;;
(d) ;;
(*) print "Bad ZTST_diff code: d for diff, p for pattern match" ;;
esac
shift
if (( diff_pat ))
then
local -a diff_lines1 diff_lines2
integer failed i
diff_lines1=("${(f)$(<$argv[-2])}")
diff_lines2=("${(f)$(<$argv[-1])}")
if (( ${#diff_lines1} != ${#diff_lines2} ))
then
failed=1
else
for ((i = 1; i <= ${#diff_lines1}; i++ )) do
if [[ ${diff_lines2[i]} != ${~diff_lines1[i]} ]]
then
failed=1
break
fi
done
fi
if (( failed ))
then
print -rl "Pattern match failed:" \<${^diff_lines1} \>${^diff_lines2}
diff_ret=1
fi
else
diff_out=$(diff "$@")
diff_ret="$?"
if [[ "$diff_ret" != "0" ]]
then
print -r "$diff_out"
fi
fi
return "$diff_ret"
}
ZTST_execchunk () {
setopt localloops
options=($ZTST_testopts)
() {
unsetopt localloops
eval "$ZTST_code"
}
ZTST_status=$?
ZTST_testopts=(${(kv)options[*]})
options=(${ZTST_mainopts[*]})
ZTST_verbose 2 "ZTST_execchunk: status $ZTST_status"
return $ZTST_status
}
ZTST_getchunk () {
ZTST_code=''
while [[ $ZTST_curline = [[:blank:]]# ]]
do
ZTST_getline || break
done
while [[ $ZTST_curline = [[:blank:]]##[^[:blank:]]* ]]
do
ZTST_code="${ZTST_code:+${ZTST_code}
}${ZTST_curline}"
ZTST_getline || break
done
ZTST_verbose 2 "ZTST_getchunk: read code chunk:
$ZTST_code"
[[ -n $ZTST_code ]]
}
ZTST_getline () {
local IFS=
while true
do
read -u $ZTST_input -r ZTST_curline || return 1
[[ $ZTST_curline = \#* ]] || return 0
done
}
ZTST_getredir () {
local char=${ZTST_curline[1]} fn
ZTST_redir=${ZTST_curline[2,-1]}
while ZTST_getline
do
[[ $ZTST_curline[1] = $char ]] || break
ZTST_redir="${ZTST_redir}
${ZTST_curline[2,-1]}"
done
ZTST_verbose 2 "ZTST_getredir: read redir for '$char':
$ZTST_redir"
case $char in
('<') fn=$ZTST_in ;;
('>') fn=$ZTST_out ;;
('?') fn=$ZTST_err ;;
(*) ZTST_testfailed "bad redir operator: $char"
return 1 ;;
esac
if [[ $ZTST_flags = *q* && $char = '<' ]]
then
print -r -- "${(e)ZTST_redir}" >> $fn
else
print -r -- "$ZTST_redir" >> $fn
fi
return 0
}
ZTST_getsect () {
local match mbegin mend
while [[ $ZTST_curline != '%'(#b)([[:alnum:]]##)* ]]
do
ZTST_getline || return 1
[[ $ZTST_curline = [[:blank:]]# ]] && continue
if [[ $# -eq 0 && $ZTST_curline != '%'[[:alnum:]]##* ]]
then
ZTST_testfailed "bad line found before or after section:
$ZTST_curline"
exit 1
fi
done
ZTST_getline
ZTST_cursect=${match[1]}
ZTST_verbose 2 "ZTST_getsect: read section name: $ZTST_cursect"
return 0
}
ZTST_hashmark () {
if [[ ZTST_verbose -le 0 && -t $ZTST_fd ]]
then
print -n -u$ZTST_fd -- ${(pl:SECONDS::\#::\#\r:)}
fi
(( SECONDS > COLUMNS+1 && (SECONDS -= COLUMNS) ))
}
ZTST_prepclean () {
while ZTST_getchunk
do
ZTST_execchunk > /dev/null || [[ -n $1 ]] || {
[[ -n "$ZTST_unimplemented" ]] || ZTST_testfailed "non-zero status from preparation code:
$ZTST_code" && return 0
}
done
}
ZTST_test () {
local last match mbegin mend found substlines
local diff_out diff_err
local ZTST_skip
while true
do
rm -f $ZTST_in $ZTST_out $ZTST_err
touch $ZTST_in $ZTST_out $ZTST_err
ZTST_message=''
ZTST_failmsg=''
found=0
diff_out=d
diff_err=d
ZTST_verbose 2 "ZTST_test: looking for new test"
while true
do
ZTST_verbose 2 "ZTST_test: examining line:
$ZTST_curline"
case $ZTST_curline in
(%*) if [[ $found = 0 ]]
then
break 2
else
last=1
break
fi ;;
([[:space:]]#) if [[ $found = 0 ]]
then
ZTST_getline || break 2
continue
else
break
fi ;;
([[:space:]]##[^[:space:]]*) ZTST_getchunk
if [[ $ZTST_curline = (#b)([-0-9]##)([[:alpha:]]#)(:*)# ]]
then
ZTST_xstatus=$match[1]
ZTST_flags=$match[2]
ZTST_message=${match[3]:+${match[3][2,-1]}}
else
ZTST_testfailed "expecting test status at:
$ZTST_curline"
return 1
fi
ZTST_getline
found=1 ;;
('<'*) ZTST_getredir || return 1
found=1 ;;
('*>'*) ZTST_curline=${ZTST_curline[2,-1]}
diff_out=p ;&
('>'*) ZTST_getredir || return 1
found=1 ;;
('*?'*) ZTST_curline=${ZTST_curline[2,-1]}
diff_err=p ;&
('?'*) ZTST_getredir || return 1
found=1 ;;
('F:'*) ZTST_failmsg="${ZTST_failmsg:+${ZTST_failmsg}
} ${ZTST_curline[3,-1]}"
ZTST_getline
found=1 ;;
(*) ZTST_testfailed "bad line in test block:
$ZTST_curline"
return 1 ;;
esac
done
if [[ -n $ZTST_code ]]
then
ZTST_hashmark
ZTST_verbose 1 "Running test: $ZTST_message"
ZTST_verbose 2 "ZTST_test: expecting status: $ZTST_xstatus"
ZTST_verbose 2 "Input: $ZTST_in, output: $ZTST_out, error: $ZTST_terr"
ZTST_execchunk < $ZTST_in > $ZTST_tout 2> $ZTST_terr
if [[ -n $ZTST_skip ]]
then
ZTST_verbose 0 "Test case skipped: $ZTST_skip"
ZTST_skip=
if [[ -n $last ]]
then
break
else
continue
fi
fi
if [[ $ZTST_xstatus != - && $ZTST_xstatus != $ZTST_status ]]
then
ZTST_testfailed "bad status $ZTST_status, expected $ZTST_xstatus from:
$ZTST_code${$(<$ZTST_terr):+
Error output:
$(<$ZTST_terr)}"
return 1
fi
ZTST_verbose 2 "ZTST_test: test produced standard output:
$(<$ZTST_tout)
ZTST_test: and standard error:
$(<$ZTST_terr)"
if [[ $ZTST_flags = *q* && -s $ZTST_out ]]
then
substlines="$(<$ZTST_out)"
rm -rf $ZTST_out
print -r -- "${(e)substlines}" > $ZTST_out
fi
if [[ $ZTST_flags != *d* ]] && ! ZTST_diff $diff_out -c $ZTST_out $ZTST_tout
then
ZTST_testfailed "output differs from expected as shown above for:
$ZTST_code${$(<$ZTST_terr):+
Error output:
$(<$ZTST_terr)}"
return 1
fi
if [[ $ZTST_flags = *q* && -s $ZTST_err ]]
then
substlines="$(<$ZTST_err)"
rm -rf $ZTST_err
print -r -- "${(e)substlines}" > $ZTST_err
fi
if [[ $ZTST_flags != *D* ]] && ! ZTST_diff $diff_err -c $ZTST_err $ZTST_terr
then
ZTST_testfailed "error output differs from expected as shown above for:
$ZTST_code"
return 1
fi
fi
ZTST_verbose 1 "Test successful."
[[ -n $last ]] && break
done
ZTST_verbose 2 "ZTST_test: all tests successful"
ZTST_message=''
}
ZTST_testfailed () {
print -r "Test $ZTST_testname failed: $1"
if [[ -n $ZTST_message ]]
then
print -r "Was testing: $ZTST_message"
fi
print -r "$ZTST_testname: test failed."
if [[ -n $ZTST_failmsg ]]
then
print -r "The following may (or may not) help identifying the cause:
$ZTST_failmsg"
fi
ZTST_testfailed=1
return 1
}
ZTST_verbose () {
local lev=$1
shift
if [[ -n $ZTST_verbose && $ZTST_verbose -ge $lev ]]
then
print -r -u $ZTST_fd -- $*
fi
}
scope00 () {
typeset scalar
scalar=local
typeset -a array
array=(l o c a l)
print $scalar $array
}
scope01 () {
local scalar
scalar=local
local -a array
array=(l o c a l)
print $scalar $array
}
scope02 () {
declare scalar
scalar=local
declare -a array
array=(l o c a l)
print $scalar $array
}
scope10 () {
export outer=outer
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope11 () {
typeset -x outer=outer
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope12 () {
local -x outer=inner
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $outer'
}
scope13 () {
local -xT OUTER outer
outer=(i n n e r)
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh -fc 'echo $OUTER'
}
stress00 () {
typeset -h +g -m [[:alpha:]_]*
unset -m [[:alpha:]_]*
typeset +m [[:alpha:]_]*
}
tail () {
emulate -L zsh
if [[ -z $TAIL_SUPPORTS_MINUS_N ]]
then
local test
test=$(echo "foo\nbar" | command tail -n 1 2>/dev/null)
if [[ $test = bar ]]
then
TAIL_SUPPORTS_MINUS_N=1
else
TAIL_SUPPORTS_MINUS_N=0
fi
fi
integer argi=${argv[(i)-<->]}
if [[ $argi -le $# && $TAIL_SUPPORTS_MINUS_N = 1 ]]
then
argv[$argi]=(-n ${argv[$argi][2,-1]})
fi
command tail "$argv[@]"
}
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
readonly r=success
ZTST_getchunk: read code chunk:
readonly r=success
print $r
r=failure
ZTST_test: examining line:
>success
ZTST_getredir: read redir for '>':
success
ZTST_test: examining line:
?(eval):3: read-only variable: r
ZTST_getredir: read redir for '?':
(eval):3: read-only variable: r
ZTST_test: examining line:
Running test: Readonly declaration
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
success
ZTST_test: and standard error:
(eval):3: read-only variable: r
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset r=success
ZTST_getchunk: read code chunk:
typeset r=success
readonly r
print $r
r=failure
ZTST_test: examining line:
>success
ZTST_getredir: read redir for '>':
success
ZTST_test: examining line:
?(eval):4: read-only variable: r
ZTST_getredir: read redir for '?':
(eval):4: read-only variable: r
ZTST_test: examining line:
Running test: Convert to readonly
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
success
ZTST_test: and standard error:
(eval):4: read-only variable: r
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -gU array
ZTST_getchunk: read code chunk:
typeset -gU array
print $array
ZTST_test: examining line:
>a r y
ZTST_getredir: read redir for '>':
a r y
ZTST_test: examining line:
Running test: Uniquified arrays and non-local scope
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
a r y
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -T SCALAR=l:o:c:a:l array
ZTST_getchunk: read code chunk:
typeset -T SCALAR=l:o:c:a:l array
print $array
typeset -U SCALAR
print $SCALAR $array
ZTST_test: examining line:
>l o c a l
ZTST_getredir: read redir for '>':
l o c a l
l:o:c:a l o c a
ZTST_test: examining line:
Running test: Tied parameters and uniquified colon-arrays
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
l o c a l
l:o:c:a l o c a
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
(setopt NO_multibyte cbases
ZTST_getchunk: read code chunk:
(setopt NO_multibyte cbases
LC_ALL=C 2>/dev/null
typeset -T SCALAR=$'l\x83o\x83c\x83a\x83l' array $'\x83'
print $array
typeset -U SCALAR
for (( i = 1; i <= ${#SCALAR}; i++ )); do
char=$SCALAR[i]
print $(( [#16] #char ))
done
print $array)
ZTST_test: examining line:
>l o c a l
ZTST_getredir: read redir for '>':
l o c a l
0x6C
0x83
0x6F
0x83
0x63
0x83
0x61
l o c a
ZTST_test: examining line:
Running test: Tied parameters and uniquified arrays with meta-character as separator
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
l o c a l
0x6C
0x83
0x6F
0x83
0x63
0x83
0x61
l o c a
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -T SCALAR=$'l\000o\000c\000a\000l' array $'\000'
ZTST_getchunk: read code chunk:
typeset -T SCALAR=$'l\000o\000c\000a\000l' array $'\000'
typeset -U SCALAR
print $array
[[ $SCALAR == $'l\000o\000c\000a' ]]
ZTST_test: examining line:
>l o c a
ZTST_getredir: read redir for '>':
l o c a
ZTST_test: examining line:
Running test: Tied parameters and uniquified arrays with NUL-character as separator
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
l o c a
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -T SCALAR array
ZTST_getchunk: read code chunk:
typeset -T SCALAR array
typeset +T SCALAR
ZTST_test: examining line:
?(eval):typeset:2: use unset to remove tied variables
ZTST_getredir: read redir for '?':
(eval):typeset:2: use unset to remove tied variables
ZTST_test: examining line:
Running test: Untying is prohibited
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
ZTST_test: and standard error:
(eval):typeset:2: use unset to remove tied variables
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
OUTER=outer
ZTST_getchunk: read code chunk:
OUTER=outer
scope13
print $OUTER
ZTST_test: examining line:
>i:n:n:e:r
ZTST_getredir: read redir for '>':
i:n:n:e:r
outer
ZTST_test: examining line:
Running test: Export of tied parameters
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
i:n:n:e:r
outer
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -TU MORESTUFF=here-we-go-go-again morestuff '-'
ZTST_getchunk: read code chunk:
typeset -TU MORESTUFF=here-we-go-go-again morestuff '-'
print -l $morestuff
ZTST_test: examining line:
>here
ZTST_getredir: read redir for '>':
here
we
go
again
ZTST_test: examining line:
Running test: Tied arrays with separator specified
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
here
we
go
again
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -T THIS will not work
ZTST_getchunk: read code chunk:
typeset -T THIS will not work
ZTST_test: examining line:
?(eval):typeset:1: too many arguments for -T
ZTST_getredir: read redir for '?':
(eval):typeset:1: too many arguments for -T
ZTST_test: examining line:
Running test: Tied array syntax
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
ZTST_test: and standard error:
(eval):typeset:1: too many arguments for -T
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local array[2]=x
ZTST_getchunk: read code chunk:
local array[2]=x
ZTST_test: examining line:
?(eval):local:1: array[2]: can't create local array elements
ZTST_getredir: read redir for '?':
(eval):local:1: array[2]: can't create local array elements
ZTST_test: examining line:
Running test: Illegal local array element assignment
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
ZTST_test: and standard error:
(eval):local:1: array[2]: can't create local array elements
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local -a array
ZTST_getchunk: read code chunk:
local -a array
typeset array[1]=a array[2]=b array[3]=c
print $array
ZTST_test: examining line:
>a b c
ZTST_getredir: read redir for '>':
a b c
ZTST_test: examining line:
Running test: Legal local array element assignment
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
a b c
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local -A assoc
ZTST_getchunk: read code chunk:
local -A assoc
local b=1 ;: to stomp assoc[1] if assoc[b] is broken
typeset assoc[1]=a assoc[b]=2 assoc[3]=c
print $assoc[1] $assoc[b] $assoc[3]
ZTST_test: examining line:
>a 2 c
ZTST_getredir: read redir for '>':
a 2 c
ZTST_test: examining line:
Running test: Legal local associative array element assignment
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
a 2 c
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local scalar scalar[1]=a scalar[2]=b scalar[3]=c
ZTST_getchunk: read code chunk:
local scalar scalar[1]=a scalar[2]=b scalar[3]=c
print $scalar
ZTST_test: examining line:
>abc
ZTST_getredir: read redir for '>':
abc
ZTST_test: examining line:
Running test: Local scalar subscript assignment
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
abc
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -L 10 fools
ZTST_getchunk: read code chunk:
typeset -L 10 fools
for fools in " once" "twice" " thrice" " oops too long here"; do
print "'$fools'"
done
ZTST_test: examining line:
>'once '
ZTST_getredir: read redir for '>':
'once '
'twice '
'thrice '
'oops too l'
ZTST_test: examining line:
Running test: Left justification of scalars
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'once '
'twice '
'thrice '
'oops too l'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -L 10 -F 3 foolf
ZTST_getchunk: read code chunk:
typeset -L 10 -F 3 foolf
for foolf in 1.3 4.6 -2.987 -4.91031; do
print "'$foolf'"
done
ZTST_test: examining line:
>'1.300 '
ZTST_getredir: read redir for '>':
'1.300 '
'4.600 '
'-2.987 '
'-4.910 '
ZTST_test: examining line:
Running test: Left justification of floating point
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'1.300 '
'4.600 '
'-2.987 '
'-4.910 '
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -L 10 -Z foolzs
ZTST_getchunk: read code chunk:
typeset -L 10 -Z foolzs
for foolzs in 001.3 04.6 -2.987 -04.91231; do
print "'$foolzs'"
done
ZTST_test: examining line:
>'1.3 '
ZTST_getredir: read redir for '>':
'1.3 '
'4.6 '
'-2.987 '
'-04.91231 '
ZTST_test: examining line:
Running test: Left justification of scalars with zero suppression
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'1.3 '
'4.6 '
'-2.987 '
'-04.91231 '
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -R 10 foors
ZTST_getchunk: read code chunk:
typeset -R 10 foors
for foors in short longer even-longer; do
print "'$foors'"
done
ZTST_test: examining line:
>' short'
ZTST_getredir: read redir for '>':
' short'
' longer'
'ven-longer'
ZTST_test: examining line:
Running test: Right justification of scalars
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
' short'
' longer'
'ven-longer'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -Z 10 foozs
ZTST_getchunk: read code chunk:
typeset -Z 10 foozs
for foozs in 42 -42 " 43" " -43"; do
print "'$foozs'"
done
ZTST_test: examining line:
>'0000000042'
ZTST_getredir: read redir for '>':
'0000000042'
' -42'
' 000000043'
' -43'
ZTST_test: examining line:
Running test: Right justification of scalars with zeroes
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'0000000042'
' -42'
' 000000043'
' -43'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
integer -Z 10 foozi
ZTST_getchunk: read code chunk:
integer -Z 10 foozi
for foozi in 42 -42 " 43" " -43"; do
print "'$foozi'"
done
ZTST_test: examining line:
>'0000000042'
ZTST_getredir: read redir for '>':
'0000000042'
'-000000042'
'0000000043'
'-000000043'
ZTST_test: examining line:
Running test: Right justification of integers with zero, no initial base
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'0000000042'
'-000000042'
'0000000043'
'-000000043'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
unsetopt cbases
ZTST_getchunk: read code chunk:
unsetopt cbases
integer -Z 10 -i 16 foozi16
for foozi16 in 42 -42 " 43" " -43"; do
print "'$foozi16'"
done
ZTST_test: examining line:
>'16#000002A'
ZTST_getredir: read redir for '>':
'16#000002A'
'-16#00002A'
'16#000002B'
'-16#00002B'
ZTST_test: examining line:
Running test: Right justification of integers with zero, base 16, C_BASES off
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'16#000002A'
'-16#00002A'
'16#000002B'
'-16#00002B'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
setopt cbases
ZTST_getchunk: read code chunk:
setopt cbases
integer -Z 10 -i 16 foozi16c
for foozi16c in 42 -42 " 43" " -43"; do
print "'$foozi16c'"
done
ZTST_test: examining line:
>'0x0000002A'
ZTST_getredir: read redir for '>':
'0x0000002A'
'-0x000002A'
'0x0000002B'
'-0x000002B'
ZTST_test: examining line:
Running test: Right justification of integers with zero, base 16, C_BASES on
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'0x0000002A'
'-0x000002A'
'0x0000002B'
'-0x000002B'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
setopt cbases
ZTST_getchunk: read code chunk:
setopt cbases
integer -Z 10 -i 16 foozi16c
for foozi16c in 0x1234 -0x1234; do
for (( i = 1; i <= 5; i++ )); do
print "'${foozi16c[i,11-i]}'"
done
print "'${foozi16c[-2]}'"
done
ZTST_test: examining line:
>'0x00001234'
ZTST_getredir: read redir for '>':
'0x00001234'
'x0000123'
'000012'
'0001'
'00'
'3'
'-0x0001234'
'0x000123'
'x00012'
'0001'
'00'
'3'
ZTST_test: examining line:
Running test: Extracting substrings from padded integers
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'0x00001234'
'x0000123'
'000012'
'0001'
'00'
'3'
'-0x0001234'
'0x000123'
'x00012'
'0001'
'00'
'3'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -F 3 -Z 10 foozf
ZTST_getchunk: read code chunk:
typeset -F 3 -Z 10 foozf
for foozf in 3.14159 -3.14159 4 -4; do
print "'$foozf'"
done
ZTST_test: examining line:
>'000003.142'
ZTST_getredir: read redir for '>':
'000003.142'
'-00003.142'
'000004.000'
'-00004.000'
ZTST_test: examining line:
Running test: Right justification of fixed point numbers with zero
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
'000003.142'
'-00003.142'
'000004.000'
'-00004.000'
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
stress00
ZTST_getchunk: read code chunk:
stress00
print $scalar $array
ZTST_test: examining line:
>scalar a r y
ZTST_getredir: read redir for '>':
scalar a r y
ZTST_test: examining line:
Running test: Stress test: all parameters are local and unset, using -m
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
scalar a r y
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local parentenv=preserved
ZTST_getchunk: read code chunk:
local parentenv=preserved
fn() {
typeset -h +g -m \*
unset -m \*
integer i=9
float -H f=9
declare -t scalar
declare -H -a array
typeset
typeset +
}
fn
echo $parentenv
ZTST_test: examining line:
>array local array
ZTST_getredir: read redir for '>':
array local array
float local f
integer local i=9
local tagged scalar=''
array local array
float local f
integer local i
local tagged scalar
preserved
ZTST_test: examining line:
Running test: Parameter hiding and tagging, printing types and values
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
array local array
float local f
integer local i=9
local tagged scalar=''
array local array
float local f
integer local i
local tagged scalar
preserved
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
export ENVFOO=bar
ZTST_getchunk: read code chunk:
export ENVFOO=bar
print ENVFOO in environment
env | grep '^ENVFOO'
print Changing ENVFOO
ENVFOO="not bar any more"
env | grep '^ENVFOO'
unset ENVFOO
print ENVFOO no longer in environment
env | grep '^ENVFOO'
ZTST_test: examining line:
>ENVFOO in environment
ZTST_getredir: read redir for '>':
ENVFOO in environment
ENVFOO=bar
Changing ENVFOO
ENVFOO=not bar any more
ENVFOO no longer in environment
ZTST_test: examining line:
Running test: Adding and removing values to and from the environment
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
ENVFOO in environment
ENVFOO=bar
Changing ENVFOO
ENVFOO=not bar any more
ENVFOO no longer in environment
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
(export FOOENV=BAR
ZTST_getchunk: read code chunk:
(export FOOENV=BAR
env | grep '^FOOENV'
print Exec
exec $ZTST_testdir/../Src/zsh -fc '
print Unset
unset FOOENV
env | grep "^FOOENV"')
ZTST_test: examining line:
>FOOENV=BAR
ZTST_getredir: read redir for '>':
FOOENV=BAR
Exec
Unset
ZTST_test: examining line:
Running test: Can unset environment variables after exec
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
FOOENV=BAR
Exec
Unset
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local case1=upper
ZTST_getchunk: read code chunk:
local case1=upper
typeset -u case1
print $case1
upper="VALUE OF \$UPPER"
print ${(P)case1}
ZTST_test: examining line:
>UPPER
ZTST_getredir: read redir for '>':
UPPER
VALUE OF $UPPER
ZTST_test: examining line:
Running test: Upper case conversion, does not apply to values used internally
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
UPPER
VALUE OF $UPPER
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local case2=LOWER
ZTST_getchunk: read code chunk:
local case2=LOWER
typeset -l case2
print $case2
LOWER="value of \$lower"
print ${(P)case2}
ZTST_test: examining line:
>lower
ZTST_getredir: read redir for '>':
lower
value of $lower
ZTST_test: examining line:
Running test: Lower case conversion, does not apply to values used internally
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
lower
value of $lower
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -a array
ZTST_getchunk: read code chunk:
typeset -a array
array=(foo bar)
fn() { typeset -p array nonexistent; }
fn
ZTST_test: examining line:
>typeset -a array
ZTST_getredir: read redir for '>':
typeset -a array
array=( foo bar )
ZTST_test: examining line:
?fn:typeset: no such variable: nonexistent
ZTST_getredir: read redir for '?':
fn:typeset: no such variable: nonexistent
ZTST_test: examining line:
Running test: declare -p shouldn't create scoped values
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
typeset -a array
array=( foo bar )
ZTST_test: and standard error:
fn:typeset: no such variable: nonexistent
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
unsetopt typesetsilent
ZTST_getchunk: read code chunk:
unsetopt typesetsilent
silent1(){ typeset -g silence; }
silent2(){ local silence; silent1; }
silent2
ZTST_test: examining line:
Running test: typeset -g should be silent even without TYPESET_SILENT
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
typeset -T TIED_SCALAR tied_array
ZTST_getchunk: read code chunk:
typeset -T TIED_SCALAR tied_array
TIED_SCALAR=foo:bar
print $tied_array
typeset -T TIED_SCALAR=goo:car tied_array
print $tied_array
typeset -T TIED_SCALAR tied_array=(poo par)
print $TIED_SCALAR
ZTST_test: examining line:
>foo bar
ZTST_getredir: read redir for '>':
foo bar
goo car
poo:par
ZTST_test: examining line:
Running test: retying arrays to same array works
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
foo bar
goo car
poo:par
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
(
ZTST_getchunk: read code chunk:
(
setopt POSIXBUILTINS
readonly pbro
print ${+pbro} >&2
(typeset pbro=3)
(pbro=4)
readonly -p | grep pbro >&2 # shows up as "readonly" although unset
typeset -r pbro # idempotent (no error)...
print ${+pbro} >&2 # ...so still readonly...
typeset +r pbro # ...can't turn it off
)
ZTST_test: examining line:
?0
ZTST_getredir: read redir for '?':
0
(eval):5: read-only variable: pbro
(eval):6: read-only variable: pbro
typeset -r pbro
0
(eval):10: read-only variable: pbro
ZTST_test: examining line:
Running test: readonly with POSIX_BUILTINS
ZTST_test: expecting status: 1
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 1
ZTST_test: test produced standard output:
ZTST_test: and standard error:
0
(eval):5: read-only variable: pbro
(eval):6: read-only variable: pbro
typeset -r pbro
0
(eval):10: read-only variable: pbro
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
readonly foo=bar novalue
ZTST_getchunk: read code chunk:
readonly foo=bar novalue
readonly -p
ZTST_test: examining line:
>typeset -r foo=bar
ZTST_getredir: read redir for '>':
typeset -r foo=bar
typeset -r novalue=''
ZTST_test: examining line:
Running test: readonly -p output (no readonly specials)
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
typeset -r foo=bar
typeset -r novalue=''
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
local -a a1 a2
ZTST_getchunk: read code chunk:
local -a a1 a2
local -r r1=yes r2=no
a1=(one two) a2=(three four)
readonly a1
typeset -pm 'a[12]'
typeset -pm 'r[12]'
ZTST_test: examining line:
>typeset -a a1
ZTST_getredir: read redir for '>':
typeset -a a1
a1=( one two )
typeset -ar a1
typeset -a a2
a2=( three four )
typeset -r r1=yes
typeset -r r2=no
ZTST_test: examining line:
Running test: readonly -p output
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
typeset -a a1
a1=( one two )
typeset -ar a1
typeset -a a2
a2=( three four )
typeset -r r1=yes
typeset -r r2=no
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
one=hidden two=hidden three=hidden four=hidden five=hidden
ZTST_getchunk: read code chunk:
one=hidden two=hidden three=hidden four=hidden five=hidden
fn() {
local bleugh="four=vier"
typeset -R10 one=eins two=(zwei dio) three $bleugh five=(cinq cinque)
three=drei
print -l $one $two $three $four $five
}
fn
print -l $one $two $three $four $five
ZTST_test: examining line:
> eins
ZTST_getredir: read redir for '>':
eins
zwei
dio
drei
vier
cinq
cinque
hidden
hidden
hidden
hidden
hidden
ZTST_test: examining line:
Running test: typeset reserved word interface: basic
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
eins
zwei
dio
drei
vier
cinq
cinque
hidden
hidden
hidden
hidden
hidden
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
(
ZTST_getchunk: read code chunk:
(
setopt glob
mkdir -p arrayglob
touch arrayglob/{one,two,three,four,five,six,seven}
fn() {
typeset array=(arrayglob/[tf]*)
print -l ${array:t}
#
typeset {first,second,third}=the_same_value array=(
extends
over
multiple
lines
)
print -l $first $second $third "$array"
#
integer i=$(echo 1 + 2 + 3 + 4)
print $i
#
# only noted by accident this was broken..
# we need to turn off special recognition
# of assignments within assignments...
typeset careful=( i=1 j=2 k=3 )
print -l $careful
}
fn
)
ZTST_test: examining line:
>five
ZTST_getredir: read redir for '>':
five
four
three
two
the_same_value
the_same_value
the_same_value
extends over multiple lines
10
i=1
j=2
k=3
ZTST_test: examining line:
Running test: typeset reserved word, more complicated cases
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
five
four
three
two
the_same_value
the_same_value
the_same_value
extends over multiple lines
10
i=1
j=2
k=3
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
(
ZTST_getchunk: read code chunk:
(
# reserved word is recognised at parsing.
# yes, this is documented.
# anyway, that means we need to
# re-eval the function...
fn='
fn() {
typeset foo=`echo one word=two`
print $foo
print $word
}
'
print reserved
eval $fn; fn
print builtin
disable -r typeset
eval $fn; fn
enable -r typeset
disable typeset
print reserved
eval $fn; fn
)
ZTST_test: examining line:
>reserved
ZTST_getredir: read redir for '>':
reserved
one word=two
builtin
one
two
reserved
one word=two
ZTST_test: examining line:
Running test: reserved word and builtin interfaces
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
reserved
one word=two
builtin
one
two
reserved
one word=two
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
fn() {
ZTST_getchunk: read code chunk:
fn() {
emulate -L zsh
setopt typeset_silent
local k
typeset -A hash=(k1 v1 k2 v2)
typeset foo=word array=(more than one word)
for k in ${(ko)hash}; do
print $k $hash[$k]
done
print -l $foo $array
typeset -A hash
typeset foo array
for k in ${(ko)hash}; do
print $k $hash[$k]
done
print -l $foo $array
typeset hash=(k3 v3 k4 v4) array=(odd number here)
for k in ${(ko)hash}; do
print $k $hash[$k]
done
print -l $array
}
fn
ZTST_test: examining line:
>k1 v1
ZTST_getredir: read redir for '>':
k1 v1
k2 v2
word
more
than
one
word
k1 v1
k2 v2
word
more
than
one
word
k3 v3
k4 v4
odd
number
here
ZTST_test: examining line:
Running test: typeset preserves existing variable types
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
k1 v1
k2 v2
word
more
than
one
word
k1 v1
k2 v2
word
more
than
one
word
k3 v3
k4 v4
odd
number
here
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
fn() { typeset foo bar thing=this stuff=(that other) more=woevva; }
ZTST_getchunk: read code chunk:
fn() { typeset foo bar thing=this stuff=(that other) more=woevva; }
which -x2 fn
fn2() { typeset assignfirst=(why not); }
which -x2 fn2
ZTST_test: examining line:
>fn () {
ZTST_getredir: read redir for '>':
fn () {
typeset foo bar thing=this stuff=(that other) more=woevva
}
fn2 () {
typeset assignfirst=(why not)
}
ZTST_test: examining line:
Running test: text output from typeset
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
fn () {
typeset foo bar thing=this stuff=(that other) more=woevva
}
fn2 () {
typeset assignfirst=(why not)
}
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
fn() {
ZTST_getchunk: read code chunk:
fn() {
typeset array=()
print ${(t)array} ${#array}
typeset gnothergarray=() gnothergarray[1]=yes gnothergarray[2]=no
print -l ${(t)gnothergarray} $gnothergarray
}
fn
ZTST_test: examining line:
>array-local 0
ZTST_getredir: read redir for '>':
array-local 0
array-local
yes
no
ZTST_test: examining line:
Running test: can set empty array
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
array-local 0
array-local
yes
no
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
array=(nothing to see here)
ZTST_getchunk: read code chunk:
array=(nothing to see here)
fn() {
typeset array=(one two three four five)
typeset array[2,4]=(umm er)
print ${#array} $array
typeset array[2,3]=()
print ${#array} $array
}
fn
print ${#array} $array
ZTST_test: examining line:
>4 one umm er five
ZTST_getredir: read redir for '>':
4 one umm er five
2 one five
4 nothing to see here
ZTST_test: examining line:
Running test: can update array slices in typeset
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
4 one umm er five
2 one five
4 nothing to see here
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: examining line:
array=(no really nothing here)
ZTST_getchunk: read code chunk:
array=(no really nothing here)
fn() {
typeset array=() array[2]=two array[4]=four
typeset -p array
typeset array=() array[3]=three array[1]=one
typeset -p array
}
fn
print $array
ZTST_test: examining line:
>typeset -a array
ZTST_getredir: read redir for '>':
typeset -a array
array=( '' two '' four )
typeset -a array
array=( one '' three )
no really nothing here
ZTST_test: examining line:
Running test: setting empty array in typeset
ZTST_test: expecting status: 0
Input: /tmp/zsh.ztst.in.18963, output: /tmp/zsh.ztst.out.18963, error: /tmp/zsh.ztst.terr.18963
ZTST_execchunk: status 0
ZTST_test: test produced standard output:
typeset -a array
array=( '' two '' four )
typeset -a array
array=( one '' three )
no really nothing here
ZTST_test: and standard error:
Test successful.
ZTST_test: looking for new test
ZTST_test: examining line:
ZTST_test: all tests successful
./ztst.zsh:540: parse error near `*'
./B03print.ztst: starting.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 2:21 bug#22420: Zsh test failure Leo Famulari
@ 2016-01-21 21:02 ` Ludovic Courtès
2016-01-21 23:05 ` Leo Famulari
2016-01-21 22:20 ` Leo Famulari
2018-09-10 0:10 ` Leo Famulari
2 siblings, 1 reply; 14+ messages in thread
From: Ludovic Courtès @ 2016-01-21 21:02 UTC (permalink / raw)
To: Leo Famulari; +Cc: 22420
Leo Famulari <leo@famulari.name> skribis:
> Zsh fails to build due to a test failure on my system (x86_64).
>
> The test suite does not report where the failure occurs but I believe it
> is in section 'Test/B02typeset.ztst' as a result of patch-shebang
> failing to find a binary interpreter for 'Test/ztst.zsh':
>
> patch-shebang: ./Test/ztst.zsh: warning: no binary for interpreter `zsh' found in $PATH
>
> I wonder if this means that the file is being interpreted by Bash, or
> maybe the 'sh' mode of Bash.
It means that the ztst.zsh contains #!/usr/bin/zsh or similar, and when
the ‘patch-shebangs’ phase runs, there’s no ‘zsh’ binary in $PATH, so
the file is left unpatched with its bogus shebang.
That means that attempts to exec ztst.zsh systematically fail.
However, I see that Zsh appears to build fine on x86_64-linux as of
v0.9.0-1121-gaca738f. What Guix commit are you using?
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 2:21 bug#22420: Zsh test failure Leo Famulari
2016-01-21 21:02 ` Ludovic Courtès
@ 2016-01-21 22:20 ` Leo Famulari
2016-01-21 23:14 ` Leo Famulari
2018-09-10 0:10 ` Leo Famulari
2 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-21 22:20 UTC (permalink / raw)
To: 22420
I patched the shebangs in "Test/ztst.zsh" and "Test/runtests.zsh" to use
the 'zsh' produced by the build phase, but it doesn't seem to have made
any difference.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 21:02 ` Ludovic Courtès
@ 2016-01-21 23:05 ` Leo Famulari
2016-01-22 15:04 ` Ludovic Courtès
0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-21 23:05 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 22420
On Thu, Jan 21, 2016 at 10:02:53PM +0100, Ludovic Courtès wrote:
> Leo Famulari <leo@famulari.name> skribis:
>
> > Zsh fails to build due to a test failure on my system (x86_64).
> >
> > The test suite does not report where the failure occurs but I believe it
> > is in section 'Test/B02typeset.ztst' as a result of patch-shebang
> > failing to find a binary interpreter for 'Test/ztst.zsh':
> >
> > patch-shebang: ./Test/ztst.zsh: warning: no binary for interpreter `zsh' found in $PATH
> >
> > I wonder if this means that the file is being interpreted by Bash, or
> > maybe the 'sh' mode of Bash.
>
> It means that the ztst.zsh contains #!/usr/bin/zsh or similar, and when
> the ‘patch-shebangs’ phase runs, there’s no ‘zsh’ binary in $PATH, so
> the file is left unpatched with its bogus shebang.
>
> That means that attempts to exec ztst.zsh systematically fail.
>
> However, I see that Zsh appears to build fine on x86_64-linux as of
> v0.9.0-1121-gaca738f. What Guix commit are you using?
Currently, feb767b23c7c. I noticed it was failing on core-updates and
decided to investigate; this commit is on master, not core-updates.
I have confirmed the failure is in 'Test/B02typeset.ztst'.
>
> Thanks,
> Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 22:20 ` Leo Famulari
@ 2016-01-21 23:14 ` Leo Famulari
0 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2016-01-21 23:14 UTC (permalink / raw)
To: 22420
On Thu, Jan 21, 2016 at 05:20:18PM -0500, Leo Famulari wrote:
> I patched the shebangs in "Test/ztst.zsh" and "Test/runtests.zsh" to use
> the 'zsh' produced by the build phase, but it doesn't seem to have made
> any difference.
I realized that the test suite sets 'ZTST_exe=../Src/zsh' and generally
takes care to execute Zsh scripts using that interpreter.
>
>
>
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 23:05 ` Leo Famulari
@ 2016-01-22 15:04 ` Ludovic Courtès
2016-01-22 16:30 ` Leo Famulari
0 siblings, 1 reply; 14+ messages in thread
From: Ludovic Courtès @ 2016-01-22 15:04 UTC (permalink / raw)
To: Leo Famulari; +Cc: 22420
Leo Famulari <leo@famulari.name> skribis:
> On Thu, Jan 21, 2016 at 10:02:53PM +0100, Ludovic Courtès wrote:
>> Leo Famulari <leo@famulari.name> skribis:
>>
>> > Zsh fails to build due to a test failure on my system (x86_64).
>> >
>> > The test suite does not report where the failure occurs but I believe it
>> > is in section 'Test/B02typeset.ztst' as a result of patch-shebang
>> > failing to find a binary interpreter for 'Test/ztst.zsh':
>> >
>> > patch-shebang: ./Test/ztst.zsh: warning: no binary for interpreter `zsh' found in $PATH
>> >
>> > I wonder if this means that the file is being interpreted by Bash, or
>> > maybe the 'sh' mode of Bash.
>>
>> It means that the ztst.zsh contains #!/usr/bin/zsh or similar, and when
>> the ‘patch-shebangs’ phase runs, there’s no ‘zsh’ binary in $PATH, so
>> the file is left unpatched with its bogus shebang.
>>
>> That means that attempts to exec ztst.zsh systematically fail.
>>
>> However, I see that Zsh appears to build fine on x86_64-linux as of
>> v0.9.0-1121-gaca738f. What Guix commit are you using?
>
> Currently, feb767b23c7c. I noticed it was failing on core-updates and
> decided to investigate; this commit is on master, not core-updates.
On my x86_64 machine, commit, I’ve just run:
--8<---------------cut here---------------start------------->8---
$ ./pre-inst-env guix build zsh --rounds=3 -K --no-substitutes
[...]
@ build-succeeded /gnu/store/0g7d2ccznwrw010mlfjzzgvycc28vfyx-zsh-5.1.1.drv -
/gnu/store/1wv2flclz8nnkiq1j1s2aphqp9lk68i6-zsh-5.1.1
$ guix hash -r /gnu/store/1wv2flclz8nnkiq1j1s2aphqp9lk68i6-zsh-5.1.1
0s634s0z2b53fj3yd16bydh0qqh1xqjsjnwr59lbkqpd7yprpqma
$ git describe
v0.9.0-1135-gedfa91a
--8<---------------cut here---------------end--------------->8---
What system are you using?
> I have confirmed the failure is in 'Test/B02typeset.ztst'.
Could you post the relevant part of the build log?
TIA,
Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 15:04 ` Ludovic Courtès
@ 2016-01-22 16:30 ` Leo Famulari
2016-01-22 17:47 ` Ludovic Courtès
0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-22 16:30 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 22420
On Fri, Jan 22, 2016 at 04:04:35PM +0100, Ludovic Courtès wrote:
> Leo Famulari <leo@famulari.name> skribis:
>
> > On Thu, Jan 21, 2016 at 10:02:53PM +0100, Ludovic Courtès wrote:
> >> Leo Famulari <leo@famulari.name> skribis:
> >>
> >> > Zsh fails to build due to a test failure on my system (x86_64).
> >> >
> [...]
>
> What system are you using?
It's an up-to-date Debian testing with this uname:
Linux host 4.3.0-1-amd64 #1 SMP Debian 4.3.3-5 (2016-01-04) x86_64 GNU/Linux
I have a machine with different hardware but the same arch, same OS
version (but different setup) and same kernel config, and it built fine
there. I can also build it in an up-to-date QEMU x86_64 image of GuixSD.
>
> > I have confirmed the failure is in 'Test/B02typeset.ztst'.
>
> Could you post the relevant part of the build log?
Here is the verbose output of only the B02 test:
http://paste.debian.net/367077/
And the non-verbose output of the entire test suite (the full verbose
log is ~40000 lines):
phase `build' succeeded after 45.8 seconds
starting phase `check'
cd Test ; make check
make[1]: Entering directory '/tmp/guix-build-zsh-5.1.1.drv-0/zsh-5.1.1/Test'
if test -n "gcc"; then \
cd .. && DESTDIR= \
make MODDIR=`pwd`/Test/Modules install.modules > /dev/null; \
fi
if ZTST_testlist="`for f in ./*.ztst; \
do echo $f; done`" \
ZTST_srcdir="." \
ZTST_exe=../Src/zsh \
../Src/zsh +Z -f ./runtests.zsh; then \
stat=0; \
else \
stat=1; \
fi; \
sleep 1; \
rm -rf Modules .zcompdump; \
exit $stat
./A01grammar.ztst: starting.
This test hangs the shell when it fails...
./A01grammar.ztst: all tests successful.
./A02alias.ztst: starting.
This test hangs the shell when it fails...
./A02alias.ztst: all tests successful.
./A03quoting.ztst: starting.
./A03quoting.ztst: all tests successful.
./A04redirect.ztst: starting.
./A04redirect.ztst: all tests successful.
./A05execution.ztst: starting.
Unable to change MONITOR option
This test takes 5 seconds to fail...
Skipping pipe leak test, requires MONITOR option
This test takes 3 seconds and hangs the shell when it fails...
./A05execution.ztst: all tests successful.
./A06assign.ztst: starting.
./A06assign.ztst: all tests successful.
./A07control.ztst: starting.
./A07control.ztst: all tests successful.
./B01cd.ztst: starting.
./B01cd.ztst: all tests successful.
./B02typeset.ztst: starting.
./ztst.zsh:540: parse error near `*'
./B03print.ztst: starting.
./B03print.ztst: all tests successful.
./B04read.ztst: starting.
./B04read.ztst: all tests successful.
./B05eval.ztst: starting.
./B05eval.ztst: all tests successful.
./B06fc.ztst: starting.
./B06fc.ztst: all tests successful.
./B07emulate.ztst: starting.
./B07emulate.ztst: all tests successful.
./B08shift.ztst: starting.
./B08shift.ztst: all tests successful.
./C01arith.ztst: starting.
./C01arith.ztst: all tests successful.
./C02cond.ztst: starting.
Warning: Not testing [[ -b blockdevice ]] (no devices found)
Warning: Not testing [[ -f blockdevice ]] (no devices found)
This test takes two seconds...
./C02cond.ztst: all tests successful.
./C03traps.ztst: starting.
This test takes at least three seconds...
This test, too, takes at least three seconds...
Another test that takes three seconds
./C03traps.ztst: all tests successful.
./C04funcdef.ztst: starting.
./C04funcdef.ztst: all tests successful.
./C05debug.ztst: starting.
./C05debug.ztst: all tests successful.
./D01prompt.ztst: starting.
./D01prompt.ztst: all tests successful.
./D02glob.ztst: starting.
./D02glob.ztst: all tests successful.
./D03procsubst.ztst: starting.
./D03procsubst.ztst: all tests successful.
./D04parameter.ztst: starting.
./D04parameter.ztst: all tests successful.
./D05array.ztst: starting.
./D05array.ztst: all tests successful.
./D06subscript.ztst: starting.
./D06subscript.ztst: all tests successful.
./D07multibyte.ztst: starting.
Testing multibyte with locale en_US.UTF-8
./D07multibyte.ztst: all tests successful.
./D08cmdsubst.ztst: starting.
./D08cmdsubst.ztst: all tests successful.
./D09brace.ztst: starting.
./D09brace.ztst: all tests successful.
./E01options.ztst: starting.
This test hangs the shell when it fails...
./E01options.ztst: all tests successful.
./E02xtrace.ztst: starting.
./E02xtrace.ztst: all tests successful.
./V01zmodload.ztst: starting.
./V01zmodload.ztst: all tests successful.
./V02zregexparse.ztst: starting.
./V02zregexparse.ztst: all tests successful.
./V03mathfunc.ztst: starting.
./V03mathfunc.ztst: all tests successful.
./V04features.ztst: starting.
./V04features.ztst: all tests successful.
./V05styles.ztst: starting.
./V05styles.ztst: all tests successful.
./V06parameter.ztst: starting.
./V06parameter.ztst: all tests successful.
./V07pcre.ztst: starting.
Testing PCRE multibyte with locale en_US.UTF-8
./V07pcre.ztst: all tests successful.
./V08zpty.ztst: starting.
./V08zpty.ztst: all tests successful.
./V09datetime.ztst: starting.
Test case skipped: Japanese UTF-8 locale not supported
./V09datetime.ztst: all tests successful.
./W01history.ztst: starting.
./W01history.ztst: all tests successful.
./X02zlevi.ztst: starting.
./X02zlevi.ztst: all tests successful.
./Y01completion.ztst: starting.
./Y01completion.ztst: all tests successful.
./Y02compmatch.ztst: starting.
./Y02compmatch.ztst: all tests successful.
./Y03arguments.ztst: starting.
./Y03arguments.ztst: all tests successful.
**************************************
44 successful test scripts, 1 failure, 0 skipped
**************************************
Makefile:189: recipe for target 'check' failed
make[1]: *** [check] Error 1
make[1]: Leaving directory '/tmp/guix-build-zsh-5.1.1.drv-0/zsh-5.1.1/Test'
Makefile:265: recipe for target 'check' failed
make: *** [check] Error 2
phase `check' failed after 30.2 seconds
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 16:30 ` Leo Famulari
@ 2016-01-22 17:47 ` Ludovic Courtès
2016-01-22 19:33 ` Leo Famulari
0 siblings, 1 reply; 14+ messages in thread
From: Ludovic Courtès @ 2016-01-22 17:47 UTC (permalink / raw)
To: Leo Famulari; +Cc: 22420
Leo Famulari <leo@famulari.name> skribis:
>> > I have confirmed the failure is in 'Test/B02typeset.ztst'.
>>
>> Could you post the relevant part of the build log?
>
> Here is the verbose output of only the B02 test:
> http://paste.debian.net/367077/
It finishes with:
--8<---------------cut here---------------start------------->8---
2221 Test successful.
2222 ZTST_test: looking for new test
2223 ZTST_test: examining line:
2224
2225 ZTST_test: all tests successful
2226 ./ztst.zsh:550: unmatched "
--8<---------------cut here---------------end--------------->8---
Could it be that the unmatched " is the root cause? I don’t see any
clear sign of an error or failure other than that.
Could you check what’s in that file on line 550?
My 2¢.
Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 17:47 ` Ludovic Courtès
@ 2016-01-22 19:33 ` Leo Famulari
2016-01-22 20:34 ` Ludovic Courtès
0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-22 19:33 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 22420
On Fri, Jan 22, 2016 at 06:47:29PM +0100, Ludovic Courtès wrote:
> Leo Famulari <leo@famulari.name> skribis:
>
> >> > I have confirmed the failure is in 'Test/B02typeset.ztst'.
> >>
> >> Could you post the relevant part of the build log?
> >
> > Here is the verbose output of only the B02 test:
> > http://paste.debian.net/367077/
>
> It finishes with:
>
> --8<---------------cut here---------------start------------->8---
> 2221 Test successful.
> 2222 ZTST_test: looking for new test
> 2223 ZTST_test: examining line:
> 2224
> 2225 ZTST_test: all tests successful
> 2226 ./ztst.zsh:550: unmatched "
> --8<---------------cut here---------------end--------------->8---
>
> Could it be that the unmatched " is the root cause? I don’t see any
> clear sign of an error or failure other than that.
>
> Could you check what’s in that file on line 550?
It's only 543 lines long! :o
I guess I'll try tracing the script.
I thought that perhaps it was referring to B02typeset.ztst, but I don't
think there is anything related in that area of the file:
540 (
541 setopt glob
542 mkdir -p arrayglob
543 touch arrayglob/{one,two,three,four,five,six,seven}
544 fn() {
545 typeset array=(arrayglob/[tf]*)
546 print -l ${array:t}
547 #
548 typeset {first,second,third}=the_same_value array=(
549 extends
550 over
551 multiple
552 lines
553 )
554 print -l $first $second $third "$array"
555 #
556 integer i=$(echo 1 + 2 + 3 + 4)
557 print $i
558 #
559 # only noted by accident this was broken..
560 # we need to turn off special recognition
561 # of assignments within assignments...
562 typeset careful=( i=1 j=2 k=3 )
563 print -l $careful
564 }
>
> My 2¢.
>
> Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 19:33 ` Leo Famulari
@ 2016-01-22 20:34 ` Ludovic Courtès
2016-01-22 20:38 ` Leo Famulari
0 siblings, 1 reply; 14+ messages in thread
From: Ludovic Courtès @ 2016-01-22 20:34 UTC (permalink / raw)
To: Leo Famulari; +Cc: 22420
Leo Famulari <leo@famulari.name> skribis:
> I thought that perhaps it was referring to B02typeset.ztst, but I don't
> think there is anything related in that area of the file:
> 540 (
> 541 setopt glob
> 542 mkdir -p arrayglob
> 543 touch arrayglob/{one,two,three,four,five,six,seven}
> 544 fn() {
> 545 typeset array=(arrayglob/[tf]*)
Out of curiosity, what file system is this on?
Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 20:34 ` Ludovic Courtès
@ 2016-01-22 20:38 ` Leo Famulari
2016-01-22 20:43 ` Leo Famulari
0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-22 20:38 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 22420
On Fri, Jan 22, 2016 at 09:34:39PM +0100, Ludovic Courtès wrote:
> Leo Famulari <leo@famulari.name> skribis:
>
> > I thought that perhaps it was referring to B02typeset.ztst, but I don't
> > think there is anything related in that area of the file:
> > 540 (
> > 541 setopt glob
> > 542 mkdir -p arrayglob
> > 543 touch arrayglob/{one,two,three,four,five,six,seven}
> > 544 fn() {
> > 545 typeset array=(arrayglob/[tf]*)
>
> Out of curiosity, what file system is this on?
Both filesystems are btrfs on LVM. The failing system is also using
LUKS.
>
> Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 20:38 ` Leo Famulari
@ 2016-01-22 20:43 ` Leo Famulari
2016-01-23 10:51 ` Ludovic Courtès
0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2016-01-22 20:43 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 22420
On Fri, Jan 22, 2016 at 03:38:54PM -0500, Leo Famulari wrote:
> On Fri, Jan 22, 2016 at 09:34:39PM +0100, Ludovic Courtès wrote:
> > Leo Famulari <leo@famulari.name> skribis:
> >
> > > I thought that perhaps it was referring to B02typeset.ztst, but I don't
> > > think there is anything related in that area of the file:
> > > 540 (
> > > 541 setopt glob
> > > 542 mkdir -p arrayglob
> > > 543 touch arrayglob/{one,two,three,four,five,six,seven}
> > > 544 fn() {
> > > 545 typeset array=(arrayglob/[tf]*)
> >
> > Out of curiosity, what file system is this on?
>
> Both filesystems are btrfs on LVM. The failing system is also using
> LUKS.
Well, actually, that only describes /home, which is perhaps not
relevant, although I did try and fail to build in a `guix environment
zsh` "by hand" in /home on the failing machine.
Failing system (separate /tmp):
/tmp /dev/mapper/bad--vg-tmp on /tmp type ext4 (rw,relatime,stripe=4,data=ordered)
Working system (/tmp on /):
/dev/mapper/good--vg-root on / type ext4 (rw,relatime,errors=remount-ro,data=ordered)
>
> >
> > Ludo’.
>
>
>
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-22 20:43 ` Leo Famulari
@ 2016-01-23 10:51 ` Ludovic Courtès
0 siblings, 0 replies; 14+ messages in thread
From: Ludovic Courtès @ 2016-01-23 10:51 UTC (permalink / raw)
To: Leo Famulari; +Cc: 22420
Leo Famulari <leo@famulari.name> skribis:
> On Fri, Jan 22, 2016 at 03:38:54PM -0500, Leo Famulari wrote:
>> On Fri, Jan 22, 2016 at 09:34:39PM +0100, Ludovic Courtès wrote:
>> > Leo Famulari <leo@famulari.name> skribis:
>> >
>> > > I thought that perhaps it was referring to B02typeset.ztst, but I don't
>> > > think there is anything related in that area of the file:
>> > > 540 (
>> > > 541 setopt glob
>> > > 542 mkdir -p arrayglob
>> > > 543 touch arrayglob/{one,two,three,four,five,six,seven}
>> > > 544 fn() {
>> > > 545 typeset array=(arrayglob/[tf]*)
>> >
>> > Out of curiosity, what file system is this on?
>>
>> Both filesystems are btrfs on LVM. The failing system is also using
>> LUKS.
OK. Btrfs often behaves differently from ext4, exhibiting issues in
various places.
The above test uses uses readdir(2) and friends to test glob patterns,
so this could be an area where Btrfs yields different results.
But anyway, you said /tmp is not on Btrfs.
> Well, actually, that only describes /home, which is perhaps not
> relevant, although I did try and fail to build in a `guix environment
> zsh` "by hand" in /home on the failing machine.
>
> Failing system (separate /tmp):
> /tmp /dev/mapper/bad--vg-tmp on /tmp type ext4 (rw,relatime,stripe=4,data=ordered)
>
> Working system (/tmp on /):
> /dev/mapper/good--vg-root on / type ext4 (rw,relatime,errors=remount-ro,data=ordered)
I’m not sure what could happen here. Could you try to analyze the test
log and see what exactly is failing? Once you’ve done that, you could
try to strace the test on both the “good” and the “bad” file system, to
spot the difference.
Alternately, you could leave that for upstream to solve. ;-)
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] 14+ messages in thread
* bug#22420: Zsh test failure
2016-01-21 2:21 bug#22420: Zsh test failure Leo Famulari
2016-01-21 21:02 ` Ludovic Courtès
2016-01-21 22:20 ` Leo Famulari
@ 2018-09-10 0:10 ` Leo Famulari
2 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2018-09-10 0:10 UTC (permalink / raw)
To: 22420-done
[-- Attachment #1: Type: text/plain, Size: 42 bytes --]
This issue seems to have resolved itself.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2018-09-10 0:22 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-21 2:21 bug#22420: Zsh test failure Leo Famulari
2016-01-21 21:02 ` Ludovic Courtès
2016-01-21 23:05 ` Leo Famulari
2016-01-22 15:04 ` Ludovic Courtès
2016-01-22 16:30 ` Leo Famulari
2016-01-22 17:47 ` Ludovic Courtès
2016-01-22 19:33 ` Leo Famulari
2016-01-22 20:34 ` Ludovic Courtès
2016-01-22 20:38 ` Leo Famulari
2016-01-22 20:43 ` Leo Famulari
2016-01-23 10:51 ` Ludovic Courtès
2016-01-21 22:20 ` Leo Famulari
2016-01-21 23:14 ` Leo Famulari
2018-09-10 0:10 ` Leo Famulari
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).