Results for command_.test.sh

statusoshosh_.pyosh_.cc
pass 1400
ok 111
FAIL 01414
total151515
caseoshosh_.pyosh_.ccdescription
0pass FAIL FAIL Command block
detailsdetails
1pass FAIL FAIL Permission denied
detailsdetails
2pass FAIL FAIL Not a dir
detailsdetails
3pass FAIL FAIL Name too long
detailsdetails
4pass FAIL FAIL External programs don't have _OVM in environment
detailsdetails
5pass FAIL FAIL File with no shebang is executed
detailsdetails
6pass FAIL FAIL File with relative path and no shebang is executed
detailsdetails
7pass FAIL FAIL File in relative subdirectory and no shebang is executed
detailsdetails
8pass FAIL FAIL $PATH lookup
detailsdetails
9pass FAIL FAIL filling $PATH cache, then insert the same command earlier in cache
detailsdetails
10pass FAIL FAIL filling $PATH cache, then deleting command
detailsdetails
11pass FAIL FAIL Non-executable on $PATH
detailsdetails
12pass FAIL FAIL hash without args prints the cache
detailsdetails
13pass FAIL FAIL hash with args
detailsdetails
14ok ok ok hash -r doesn't allow additional args
detailsdetailsdetails
14 passed, 3 OK, 0 not implemented, 0 BUG, 28 failed, 0 timeouts, 0 cases skipped

Details on runs that didn't PASS

osh_.py0 Command block

[osh_.py stdout] Expected '/bin/ls\n', got '(cmd_value.Argv argv:[which ls] arg_spids:[2 4])\n'

stdout:
(cmd_value.Argv argv:[which ls] arg_spids:[2 4])
stderr:
Unhandled SimpleCommand
osh_.cc0 Command block

[osh_.cc stdout] Expected '/bin/ls\n', got '(cmd_value.Argv argv:[which ls] arg_spids:[2 4])\n'

stdout:
(cmd_value.Argv argv:[which ls] arg_spids:[2 4])
stderr:
Unhandled SimpleCommand
osh_.py1 Permission denied

[osh_.py status] Expected 126, got 0

stdout:
(cmd_value.Argv argv:[touch '/text-file'] arg_spids:[0 2])
(cmd_value.Argv argv:['/text-file'] arg_spids:[5])
stderr:
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc1 Permission denied

[osh_.cc status] Expected 126, got 0

stdout:
(cmd_value.Argv argv:[touch '/text-file'] arg_spids:[0 2])
(cmd_value.Argv argv:['/text-file'] arg_spids:[5])
stderr:
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py2 Not a dir

[osh_.py status] Expected 127, got 0

stdout:
(cmd_value.Argv argv:['/not-a-dir/text-file'] arg_spids:[0])
stderr:
Unhandled SimpleCommand
osh_.cc2 Not a dir

[osh_.cc status] Expected 127, got 0

stdout:
(cmd_value.Argv argv:['/not-a-dir/text-file'] arg_spids:[0])
stderr:
Unhandled SimpleCommand
osh_.py3 Name too long

[osh_.py status] Expected 127, got 0

stdout:
(cmd_value.Argv
  argv: [
'./0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'
  ]
  arg_spids: [0]
)
stderr:
Unhandled SimpleCommand
osh_.cc3 Name too long

[osh_.cc status] Expected 127, got 0

stdout:
(cmd_value.Argv
  argv: [
'./0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789'
  ]
  arg_spids: [0]
)
stderr:
Unhandled SimpleCommand
osh_.py4 External programs don't have _OVM in environment

[osh_.py stdout] Expected 'status=1\n', got 'status=0\n'

stdout:
status=0
stderr:
osh_.cc4 External programs don't have _OVM in environment

[osh_.cc stdout] Expected 'status=1\n', got 'status=0\n'

stdout:
status=0
stderr:
osh_.py5 File with no shebang is executed

[osh_.py stdout] Expected 'hi\n', got "echo hi\n(cmd_value.Argv argv:[chmod '+x' '/no-shebang'] arg_spids:[11 13 16])\n(cmd_value.Argv argv:[-c '$TMP/no-shebang'] arg_spids:[21 23])\n"

stdout:
echo hi
(cmd_value.Argv argv:[chmod '+x' '/no-shebang'] arg_spids:[11 13 16])
(cmd_value.Argv argv:[-c '$TMP/no-shebang'] arg_spids:[21 23])
stderr:
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc5 File with no shebang is executed

[osh_.cc stdout] Expected 'hi\n', got "echo hi\n(cmd_value.Argv argv:[chmod '+x' '/no-shebang'] arg_spids:[11 13 16])\n(cmd_value.Argv argv:[-c '$TMP/no-shebang'] arg_spids:[21 23])\n"

stdout:
echo hi
(cmd_value.Argv argv:[chmod '+x' '/no-shebang'] arg_spids:[11 13 16])
(cmd_value.Argv argv:[-c '$TMP/no-shebang'] arg_spids:[21 23])
stderr:
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py6 File with relative path and no shebang is executed

[osh_.py stdout] Expected 'hi\n', got "echo hi\n(cmd_value.Argv argv:[chmod '+x' no-shebang] arg_spids:[14 16 19])\n(cmd_value.Argv argv:['' -c './no-shebang'] arg_spids:[21 25 27])\n"

stdout:
echo hi
(cmd_value.Argv argv:[chmod '+x' no-shebang] arg_spids:[14 16 19])
(cmd_value.Argv argv:['' -c './no-shebang'] arg_spids:[21 25 27])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc6 File with relative path and no shebang is executed

[osh_.cc stdout] Expected 'hi\n', got "echo hi\n(cmd_value.Argv argv:[chmod '+x' no-shebang] arg_spids:[14 16 19])\n(cmd_value.Argv argv:['' -c './no-shebang'] arg_spids:[21 25 27])\n"

stdout:
echo hi
(cmd_value.Argv argv:[chmod '+x' no-shebang] arg_spids:[14 16 19])
(cmd_value.Argv argv:['' -c './no-shebang'] arg_spids:[21 25 27])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py7 File in relative subdirectory and no shebang is executed

[osh_.py stdout] Expected 'hi\n', got "(cmd_value.Argv argv:[mkdir -p test-no-shebang] arg_spids:[4 6 8])\necho hi\n(cmd_value.Argv argv:[chmod '+x' 'test-no-shebang/script'] arg_spids:[20 22 25])\n(cmd_value.Argv argv:['' -c 'test-no-shebang/script'] arg_spids:[27 31 33])\n"

stdout:
(cmd_value.Argv argv:[mkdir -p test-no-shebang] arg_spids:[4 6 8])
echo hi
(cmd_value.Argv argv:[chmod '+x' 'test-no-shebang/script'] arg_spids:[20 22 25])
(cmd_value.Argv argv:['' -c 'test-no-shebang/script'] arg_spids:[27 31 33])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc7 File in relative subdirectory and no shebang is executed

[osh_.cc stdout] Expected 'hi\n', got "(cmd_value.Argv argv:[mkdir -p test-no-shebang] arg_spids:[4 6 8])\necho hi\n(cmd_value.Argv argv:[chmod '+x' 'test-no-shebang/script'] arg_spids:[20 22 25])\n(cmd_value.Argv argv:['' -c 'test-no-shebang/script'] arg_spids:[27 31 33])\n"

stdout:
(cmd_value.Argv argv:[mkdir -p test-no-shebang] arg_spids:[4 6 8])
echo hi
(cmd_value.Argv argv:[chmod '+x' 'test-no-shebang/script'] arg_spids:[20 22 25])
(cmd_value.Argv argv:['' -c 'test-no-shebang/script'] arg_spids:[27 31 33])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py8 $PATH lookup

[osh_.py stdout] Expected 'one\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[4 6 8 10])\necho one\necho two\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd' 'two/mycmd'] arg_spids:[32 34 37 39])\n(cmd_value.Argv argv:[mycmd] arg_spids:[46])\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[4 6 8 10])
echo one
echo two
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd' 'two/mycmd'] arg_spids:[32 34 37 39])
(cmd_value.Argv argv:[mycmd] arg_spids:[46])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc8 $PATH lookup

[osh_.cc stdout] Expected 'one\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[4 6 8 10])\necho one\necho two\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd' 'two/mycmd'] arg_spids:[32 34 37 39])\n(cmd_value.Argv argv:[mycmd] arg_spids:[46])\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[4 6 8 10])
echo one
echo two
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd' 'two/mycmd'] arg_spids:[32 34 37 39])
(cmd_value.Argv argv:[mycmd] arg_spids:[46])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py9 filling $PATH cache, then insert the same command earlier in cache

[osh_.py stdout] Expected 'two\ntwo\none\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 25])\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[38 40 43])\n(cmd_value.Argv argv:[mycmd] arg_spids:[45])\necho one\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[57 59 62])\n(cmd_value.Argv argv:[mycmd] arg_spids:[64])\n(cmd_value.Argv argv:[mycmd] arg_spids:[73])\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 25])
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[38 40 43])
(cmd_value.Argv argv:[mycmd] arg_spids:[45])
echo one
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[57 59 62])
(cmd_value.Argv argv:[mycmd] arg_spids:[64])
(cmd_value.Argv argv:[mycmd] arg_spids:[73])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc9 filling $PATH cache, then insert the same command earlier in cache

[osh_.cc stdout] Expected 'two\ntwo\none\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 25])\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[38 40 43])\n(cmd_value.Argv argv:[mycmd] arg_spids:[45])\necho one\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[57 59 62])\n(cmd_value.Argv argv:[mycmd] arg_spids:[64])\n"
[osh_.cc status] Expected 0, got -6

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 25])
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[38 40 43])
(cmd_value.Argv argv:[mycmd] arg_spids:[45])
echo one
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[57 59 62])
(cmd_value.Argv argv:[mycmd] arg_spids:[64])
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_eval.dbg: mycpp/mylib.h:648: void Dict<Str *, Str *>::clear() [K = Str *, V = Str *]: Assertion `0' failed.
osh_.py10 filling $PATH cache, then deleting command

[osh_.py stdout] Expected 'two\nstatus=0\nstatus=127\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[36 38 41])\n(cmd_value.Argv argv:[mycmd] arg_spids:[43])\nstatus=0\necho one\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[60 62 65])\n(cmd_value.Argv argv:[rm 'two/mycmd'] arg_spids:[67 69])\n(cmd_value.Argv argv:[mycmd] arg_spids:[71])\nstatus=0\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[36 38 41])
(cmd_value.Argv argv:[mycmd] arg_spids:[43])
status=0
echo one
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[60 62 65])
(cmd_value.Argv argv:[rm 'two/mycmd'] arg_spids:[67 69])
(cmd_value.Argv argv:[mycmd] arg_spids:[71])
status=0
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc10 filling $PATH cache, then deleting command

[osh_.cc stdout] Expected 'two\nstatus=0\nstatus=127\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[36 38 41])\n(cmd_value.Argv argv:[mycmd] arg_spids:[43])\nstatus=0\necho one\n(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[60 62 65])\n(cmd_value.Argv argv:[rm 'two/mycmd'] arg_spids:[67 69])\n(cmd_value.Argv argv:[mycmd] arg_spids:[71])\nstatus=0\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[36 38 41])
(cmd_value.Argv argv:[mycmd] arg_spids:[43])
status=0
echo one
(cmd_value.Argv argv:[chmod '+x' 'one/mycmd'] arg_spids:[60 62 65])
(cmd_value.Argv argv:[rm 'two/mycmd'] arg_spids:[67 69])
(cmd_value.Argv argv:[mycmd] arg_spids:[71])
status=0
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py11 Non-executable on $PATH

[osh_.py stdout] Expected 'two\nstatus=0\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])\necho one\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[46 48 51])\n(cmd_value.Argv argv:[mycmd] arg_spids:[53])\nstatus=0\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])
echo one
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[46 48 51])
(cmd_value.Argv argv:[mycmd] arg_spids:[53])
status=0
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.cc11 Non-executable on $PATH

[osh_.cc stdout] Expected 'two\nstatus=0\n', got "(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])\n(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])\necho one\necho two\n(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[46 48 51])\n(cmd_value.Argv argv:[mycmd] arg_spids:[53])\nstatus=0\n"

stdout:
(cmd_value.Argv argv:[mkdir -p one two] arg_spids:[10 12 14 16])
(cmd_value.Argv argv:[rm -f 'one/mycmd' 'two/mycmd'] arg_spids:[18 20 22 24])
echo one
echo two
(cmd_value.Argv argv:[chmod '+x' 'two/mycmd'] arg_spids:[46 48 51])
(cmd_value.Argv argv:[mycmd] arg_spids:[53])
status=0
stderr:
[??? no location ???] $HOME isn't defined
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
Unhandled SimpleCommand
osh_.py12 hash without args prints the cache

[osh_.py stdout] Expected '/usr/bin/whoami\nstatus=0\n', got '(cmd_value.Argv argv:[whoami] arg_spids:[0])\nstatus=0\n'

stdout:
(cmd_value.Argv argv:[whoami] arg_spids:[0])
status=0
stderr:
Unhandled SimpleCommand
osh_.cc12 hash without args prints the cache

[osh_.cc stdout] Expected '/usr/bin/whoami\nstatus=0\n', got '(cmd_value.Argv argv:[whoami] arg_spids:[0])\n'
[osh_.cc status] Expected 0, got -6

stdout:
(cmd_value.Argv argv:[whoami] arg_spids:[0])
stderr:
Unhandled SimpleCommand
osh_eval.dbg: mycpp/mylib.h:644: List<V> *Dict<Str *, Str *>::values() [K = Str *, V = Str *]: Assertion `0' failed.
osh_.py13 hash with args

[osh_.py stdout] Expected 'status=0\n/whoami\nstatus=1\n', got 'status=1\nstatus=1\n'

stdout:
status=1
status=1
stderr:
hash: 'whoami' not found
hash: '_nonexistent_' not found
osh_.cc13 hash with args

[osh_.cc stdout] Expected 'status=0\n/whoami\nstatus=1\n', got 'status=1\nstatus=1\n'

stdout:
status=1
status=1
stderr:
hash: 'whoami' not found
hash: '_nonexistent_' not found
osh14 hash -r doesn't allow additional args

stdout:
status=2
stderr:
  hash -r whoami >/dev/null  # avoid weird output with mksh
  ^~~~
[ stdin ]:1: 'hash' got extra arguments after -r
osh_.py14 hash -r doesn't allow additional args

stdout:
status=2
stderr:
osh_.cc14 hash -r doesn't allow additional args

stdout:
status=2
stderr: