# WJM&VMS scriptgen for GREP "spencer" tests # BEGIN { print "$ set noon"; print "$ failures=0"; } !/^#/ && NF == 3 { # # WJM&VMS GREP has option "-E" to work as EGREP # print "$ grep \"-E\" -e \"" $2 "\" SYS$INPUT: >NL:"; print $3; # # WJM&VMS GREP returns 1 instead of 0, 3 instead of 1, # otherwise an even value if(int($1)==0) { printf "$ if $STATUS.eq.1 then goto %d_end\n",++n; } else if(int($1)==1) { printf "$ if $STATUS.eq.3 then goto %d_end\n",++n; } else { printf "$ if .not.$STATUS then goto %d_end\n",++n; } printf "$ write SYS$OUTPUT \"Spencer test %d failed\"\n", n; print "$ failures=failures+1"; printf "$%d_end:\n",n; } END { print "$ exit failures.eq.0"; }