Yes I have been written this kind of code for a hundred scripts but I dont know it shows errors this time...Is it something about the shell in Solaris but I tried both ksh and bash; it gave the same error. I am sure that if test -e /etc/passwd would work.
Odd, a non-regular file "ls -l /etc/passwd" should have something differerent from a "-" for the first character (osx/darwin style /private/etc/ type setup?), but at least its not a script problem now
-e FILE
FILE exists
-f FILE
FILE exists and is a regular file