diff options
| author | s-ol <s-ol@users.noreply.github.com> | 2020-08-19 14:45:31 +0000 |
|---|---|---|
| committer | s-ol <s+removethis@s-ol.nu> | 2025-03-02 14:24:49 +0000 |
| commit | 2bc0fe723d0f5cf2be5d84545b823dec0dbfb52b (patch) | |
| tree | ba0ff0449d9f56b53e55b9d4b9ae2b68662d5073 /spec/lang/struct_spec.moon | |
| parent | add (failing) struct spec (diff) | |
| download | alive-2bc0fe723d0f5cf2be5d84545b823dec0dbfb52b.tar.gz alive-2bc0fe723d0f5cf2be5d84545b823dec0dbfb52b.zip | |
implement (set) as per spec
Diffstat (limited to 'spec/lang/struct_spec.moon')
| -rw-r--r-- | spec/lang/struct_spec.moon | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/lang/struct_spec.moon b/spec/lang/struct_spec.moon index 57c7e79..aa7b689 100644 --- a/spec/lang/struct_spec.moon +++ b/spec/lang/struct_spec.moon @@ -14,11 +14,11 @@ describe "struct", -> it "cannot add members", -> err = assert.has.error -> COPILOT\eval_once '(set (struct "a" 1) "b" 2)' - assert.matches "argument error: TBD", err + assert.matches "{a: num} has no 'b' key", err it "checks value type", -> err = assert.has.error -> COPILOT\eval_once '(set (struct "a" 1) "a" "str")' - assert.matches "argument error: TBD", err + assert.matches "expected value for key 'a' to be num, not str", err describe "(get)", -> it "can get values", -> |
