Results for ysh-builtin-ctx.test.sh

statusysh
pass 3
FAIL 5
total8
caseyshdescription
0FAIL ctx push and set
details
1FAIL ctx emit
details
2FAIL nested ctx
details
3FAIL error in context
details
4pass no context, set
5pass no context, emit
6FAIL mini-parseArgs
details
7pass ctx with value.Place, not List/Dict (error location bug fix)
3 passed, 0 OK, 0 not implemented, 0 BUG, 5 failed, 0 timeouts, 0 cases skipped
5 failed under osh

Details on runs that didn't PASS

ysh0 ctx push and set

[ysh stdout] Expected '{\n "key1": "value1",\n "key2": "value2"\n}\n' Got ''
[ysh status] Expected 0, got 2

stdout:
stderr: 
      use ///ysh/ctx.ysh
          ^
stdlib/ysh/ctx.ysh:10: 'use' may only be used at the top level
[ stdin ]:4: errexit PID 36633: command.Simple failed with status 2
ysh1 ctx emit

[ysh stdout] Expected '{\n "flag": [\n {\n "short_name": "-v"\n }\n ]\n}\n{\n "flag": [\n {\n "short_name": "-v"\n },\n {\n "short_name": "-c"\n }\n ]\n}\n{\n "flag": [\n {\n "short_name": "-v"\n },\n {\n "short_name": "-c"\n }\n ]\n}\n' Got ''
[ysh status] Expected 0, got 2

stdout:
stderr: 
      use ///ysh/ctx.ysh
          ^
stdlib/ysh/ctx.ysh:10: 'use' may only be used at the top level
[ stdin ]:4: errexit PID 36636: command.Simple failed with status 2
ysh2 nested ctx

[ysh stdout] Expected '{\n "from": "a"\n}\n{\n "from": "b"\n}\n', got ''
[ysh status] Expected 0, got 2

stdout:
stderr: 
      use ///ysh/ctx.ysh
          ^
stdlib/ysh/ctx.ysh:10: 'use' may only be used at the top level
[ stdin ]:5: errexit PID 36639: command.Simple failed with status 2
ysh3 error in context

[ysh stdout] Expected 'status=100\n', got 'status=2\n'

stdout:
status=2
stderr:
      use ///ysh/ctx.ysh
          ^
stdlib/ysh/ctx.ysh:10: 'use' may only be used at the top level
ysh6 mini-parseArgs

[ysh stdout] Expected '{\n "flag": [\n {\n "short_name": "-t",\n "long_name": "--tsv",\n "type": "Bool",\n "help": "Output as a TSV"\n },\n {\n "short_name": "-r",\n "long_name": "--recursive",\n "type": "Bool",\n "help": "Recurse into the given directory"\n },\n {\n "short_name": "-N",\n "long_name": "--count",\n "type": "Int",\n "help": "Process no more than N files"\n }\n ],\n "arg": [\n {\n "name": "path"\n }\n ]\n}\n' Got ''
[ysh status] Expected 0, got 2

stdout:
stderr: 
      use ///ysh/ctx.ysh
          ^
stdlib/ysh/ctx.ysh:10: 'use' may only be used at the top level
[ stdin ]:5: errexit PID 36651: command.Simple failed with status 2