builtin-completion () { run-file builtin-completion "$@" } 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
89 passed, 0 OK, 1 not implemented, 3 BUG, 3 failed, 0 timeouts, 0 cases skipped 3 failed under osh
osh | 0 complete with no args and complete -p both print completion spec [osh stdout] Expected "complete -W 'foo bar' mycommand\ncomplete -W 'foo bar' mycommand\ncomplete -F myfunc other\n" Got '' [osh status] Expected 0, got 2 stdout: stderr: [Commands] __fallback: ( ) actions: FileSystemAction extra: else: predicate: DefaultPredicate prefix: suffix: __first: ( ) actions: FixedWordsAction DynamicStrDictAction DynamicProcDictAction FixedWordsAction FileSystemAction ExternalCommandAction extra: else: predicate: DefaultPredicate prefix: suffix: [Patterns] complete -p ^~ [ stdin ]:7: 'complete' got invalid flag '-p' |
bash | 2 complete with nonexistent function stdout: status=0stderr: |
bash | 3 complete with no action stdout: status=0stderr: |
bash | 30 compgen -k shows Oils keywords too stdout: --stderr: |
bash | 42 Parse errors for compgen -W and complete -W stdout: status=1 status=0stderr: bash: line 1: ${: bad substitution |
osh | 44 Runtime errors for compgen -F func [osh stdout] Expected 'status=1\n', got 'foo\nbar\nstatus=0\n' stdout: foo bar status=0stderr: COMPREPLY+=( $(( 1 / 0 )) ) # FATAL, but we still have candidates ^ [ stdin ]:3: Divide by zero |
osh | 47 complete -C vs. compgen -C [osh stdout] Expected 'foo\nbar\ncompgen=0\ncomplete=0\n', got 'compgen=1\ncomplete=0\n' stdout: compgen=1 complete=0stderr: osh warning: complete -C not implemented osh warning: complete -C not implemented |