regex () { run-file regex "$@" } run-file () { local spec_name=$1; shift; sh-spec spec/$spec_name.test.sh --compare-shells --oils-bin-dir $PWD/bin "$@" }
spec test index / oilshell.org
88 passed, 7 OK, 5 not implemented, 11 BUG, 0 failed, 0 timeouts, 0 cases skipped
zsh | 0 BASH_REMATCH stdout: status=0 [''] status=1 ['']stderr: |
zsh | 4 Regex quoted with single quotes stdout: truestderr: |
zsh | 5 Regex quoted with double quotes stdout: truestderr: |
zsh | 8 Double quoting pat variable -- again bash doesn't like it. stdout: truestderr: |
zsh | 10 Regex with == and not =~ is parse error, different lexer mode required stdout: stderr: |
zsh | 12 Malformed regex stdout: stderr: zsh: parse error near `)' |
zsh | 13 Regex with | stdout: stderr: zsh: parse error near `|' |
zsh | 14 Regex to match literal brackets [] stdout: truestderr: zsh: failed to compile regex: Unmatched [, [^, [:, [., or [= |
zsh | 15 Regex to match literals . ^ $ etc. stdout: true false false falsestderr: zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression |
bash-4 | 16 Unquoted { is a regex parse error stdout: status=2stderr: |
zsh | 16 Unquoted { is a regex parse error stdout: status=1stderr: zsh: failed to compile regex: Invalid preceding regular expression |
bash-4 | 17 Fatal error inside [[ =~ ]] stdout: status=1stderr: bash-4.4: line 1: 1 / 0 : division by 0 (error token is "0 ") |
zsh | 18 Quoted { and + stdout: yes ^ yes $ yes ) yes | --- yes . --- a 0 - 1 b 0 z 0 status=0stderr: zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Invalid preceding regular expression zsh: failed to compile regex: Unmatched ( or \( zsh: failed to compile regex: Trailing backslash |
zsh | 19 Escaped { stdout: stderr: zsh: failed to compile regex: Invalid preceding regular expression |
zsh | 20 Escaped { stored in variable first stdout: ['']stderr: |
zsh | 24 pattern a=(1) stdout: status=0stderr: zsh: x not found |
zsh | 28 Multiple adjacent () groups stdout: [''] [''] [''] ['']stderr: zsh: parse error near `>>' zsh: parse error near `fi' zsh: parse error near `>>' zsh: parse error near `fi' zsh: parse error near `()' zsh: parse error near `fi' zsh: parse error near `()' zsh: parse error near `fi' |
zsh | 29 unquoted [a b] as pattern, [a b|c] stdout: yes [ab]=0 [a b]=1 yes [a b]=0stderr: zsh: condition expected: a |
zsh | 30 c|a unquoted stdout: onestderr: zsh: parse error near `|' zsh: parse error near `fi' |
zsh | 31 Operator chars ; & but not | stdout: semi=1 semi paren=1 amp=1 pipe=1 pipe=1 angle=1 newline=1stderr: zsh: parse error: condition expected: ';' zsh: parse error near `)' zsh: parse error: condition expected: '&' zsh: parse error: condition expected: '|' zsh: parse error: condition expected: 'a' zsh: parse error near `|' zsh: parse error: condition expected: '<>' zsh: parse error near `b' |
zsh | 34 Parse error with 2 words stdout: onestderr: zsh: condition expected: a zsh: parse error near `fi' |
zsh | 35 make a lisp example stdout: status=1 m=stderr: zsh: parse error near `|' |
zsh | 36 Operators and space lose meaning inside () stdout: stderr: zsh: parse error near `<' |