Skip to content

Commit

Permalink
✅ test: fix unit test error on update deps version
Browse files Browse the repository at this point in the history
  • Loading branch information
inhere committed Jun 11, 2023
1 parent 15d9de4 commit 2dd5341
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions testdata/issues59.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; exported at 2023-06-11 13:30:01
; exported at 2023-06-11 13:58:47

age = 123
baseKey = value
Expand All @@ -9,8 +9,8 @@ multiWords = hello world
name = app

[map1]
key = val
key1 = val1
key2 = val2
key = val


7 changes: 4 additions & 3 deletions toml/toml_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,11 @@ func TestDriver(t *testing.T) {
err := Decoder([]byte("invalid"), tg)
is.Err(err)

_, err = Encoder("invalid")
is.Err(err)
out, err := Encoder("invalid")
is.Eq(`"invalid"`, string(out))
is.Nil(err)

out, err := Encoder(map[string]any{"k": "v"})
out, err = Encoder(map[string]any{"k": "v"})
is.Nil(err)
is.Contains(string(out), `k = "v"`)
}

0 comments on commit 2dd5341

Please sign in to comment.