| status | ysh | ysh-cpp | |
| pass | 13 | 13 | |
| FAIL | 2 | 2 | |
| total | 15 | 15 | |
| case | ysh | ysh-cpp | description |
| 0 | pass | pass | New Obj API |
| 1 | pass | pass | Object() creates prototype chain |
| 2 | pass | pass | prototype() |
| 3 | pass | pass | propView() |
| 4 | pass | pass | Mutating method lookup with -> |
| 5 | pass | pass | Mutating method must be up the prototype chain, not on the object |
| 6 | pass | pass | Copy to Dict with dict(), and mutate |
| 7 | pass | pass | setvar obj.attr = and += and ... |
| 8 | pass | pass | obj['attr'] not allowed (for now) |
| 9 | FAIL | FAIL | setvar obj['attr'] = 3 ? |
| details | details | ||
| 10 | pass | pass | can't encode objects as JSON |
| 11 | pass | pass | Can all builtin methods with s.upper() |
| 12 | pass | pass | invokable Obj must be have prototype containing __invoke__ of value.Proc - type -t |
| 13 | pass | pass | Object with longer prototype chain |
| 14 | FAIL | FAIL | __readonly__ in prototype makes objects readonly |
| details | details |
26 passed, 0 OK, 0 not implemented, 0 BUG, 2 failed, 0 timeouts, 0 cases skipped 2 failed under osh
| ysh | 9 setvar obj['attr'] = 3 ? [ysh stdout] Expected '' Got '(Obj) ("x":99,"y":4)\n' [ysh status] Expected 3 Got 0 stdout: (Obj) ("x":99,"y":4)
stderr: |
| ysh-cpp | 9 setvar obj['attr'] = 3 ? [ysh-cpp stdout] Expected '' Got '(Obj) ("x":99,"y":4)\n' [ysh-cpp status] Expected 3 Got 0 stdout: (Obj) ("x":99,"y":4)
stderr: |
| ysh | 14 __readonly__ in prototype makes objects readonly [ysh stdout] Expected '' Got '(Obj) (__readonly__: true)\n(Int) 140647096759872\n(Int) 140647096760352\n(Obj) (x: 198) --> (__readonly__: true)\n(Int) 140647096759552\n(Int) 198\n' [ysh status] Expected 0 Got 3 stdout: (Obj) (__readonly__: true) (Int) 140647096759872 (Int) 140647096760352 (Obj) (x: 198) --> (__readonly__: true) (Int) 140647096759552 (Int) 198stderr: = keys(obj)
^~~
[ stdin ]:22: fatal: Arg 1 should be a Dict, got Obj
|
| ysh-cpp | 14 __readonly__ in prototype makes objects readonly [ysh-cpp stdout] Expected '' Got '(Obj) (__readonly__: true)\n(Int) 5457\n(Int) 10781\n(Obj) (x: 198) --> (__readonly__: true)\n(Int) 9009\n(Int) 198\n' [ysh-cpp status] Expected 0 Got 3 stdout: (Obj) (__readonly__: true) (Int) 5457 (Int) 10781 (Obj) (x: 198) --> (__readonly__: true) (Int) 9009 (Int) 198stderr: = keys(obj)
^~~
[ stdin ]:22: fatal: Arg 1 should be a Dict, got Obj
|