Skip to content

Commit

Permalink
bonsai
Browse files Browse the repository at this point in the history
  • Loading branch information
k1LoW committed Aug 27, 2022
1 parent bba38cd commit 2e19b14
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 2 additions & 2 deletions db_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ SELECT COUNT(*) AS count FROM users;
}
ctx := context.Background()
for _, tt := range tests {
func() {
t.Run(tt.stmt, func(t *testing.T) {
db, err := os.CreateTemp("", "tmp")
if err != nil {
t.Fatal(err)
Expand All @@ -90,7 +90,7 @@ SELECT COUNT(*) AS count FROM users;
if diff := cmp.Diff(got, tt.want, nil); diff != "" {
t.Errorf("%s", diff)
}
}()
})
}
}

Expand Down
10 changes: 6 additions & 4 deletions test_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ func TestBuildTree(t *testing.T) {
store map[string]interface{}
want string
}{
{"vars.key == 'hello'", map[string]interface{}{
"vars": map[string]interface{}{
"key": "hello",
{
"vars.key == 'hello'",
map[string]interface{}{
"vars": map[string]interface{}{
"key": "hello",
},
},
},
`vars.key == 'hello'
├── vars.key => "hello"
└── 'hello' => "hello"
Expand Down

0 comments on commit 2e19b14

Please sign in to comment.