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

Why does builtin 'test' differ from /usr/bin/test



From the zsh manpages:

  "test [ arg ... ]
       [ [ arg ... ] ]
              Like the system version of test.  Added for  compatibility;"...

But in zsh, the following two commands yield different results:

  test -a = '-?' -o -a = '?' && echo true           # true
  command test -a = '-?' -o -a = '?' && echo true   # not true

Why is the first (builtin) test true?	

Ronald
-- 
Ronald Otto Valentin Fischer
External Consultant at NGTA Operation
Siemens Networks Gmbh &Co. KG  http://www.siemens.com/networks 
SN MN PG P E B 2
MchM, R.32.5013 
Sankt-Martinstraße 76 
D-81541 Munich 
Phone: +49 89 636 76431
e-mail: mn-pg-p-e-b-consultant-3.com@xxxxxxxxxxx 

Siemens Networks GmbH & Co. KG - Sitz der Gesellschaft/ Registered office: München 
(Munich) - Registergericht /Commercial register: München (Munich), HRA 88537 - 
WEEE-Reg.-No. DE 52984304. Persönlich haftende Gesellschafterin /General Partner: Siemens
Networks Management GmbH - Geschäftsführer /Board of Directors: Christian Unterberger, 
Joachim Malterer, Roland Meinzer - Sitz der Gesellschaft / Registered office: München 
(Munich) - Registergericht /Commercial register: München (Munich), HRB 163416 



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