Skip to content

Commit

Permalink
fix linter issues
Browse files Browse the repository at this point in the history
  • Loading branch information
rcoreilly committed Jul 19, 2024
1 parent 67fc535 commit 3cccd72
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions interp/interp_issue_1634_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,17 @@ func TestExportClosureArg(t *testing.T) {
os.Stdout = w

i := New(Options{})
i.Use(Exports{
err := i.Use(Exports{
"tmp/tmp": map[string]reflect.Value{
"Func": reflect.ValueOf(func(s *[]func(), f func()) { *s = append(*s, f) }),
},
})
if err != nil {
t.Error(err)
}
i.ImportUsed()

_, err := i.Eval(`
_, err = i.Eval(`
func main() {
fs := []func(){}
Expand All @@ -42,7 +45,6 @@ func main() {
if err != nil {
t.Error(err)
}

// read stdout
if err = w.Close(); err != nil {
t.Fatal(err)
Expand All @@ -54,5 +56,4 @@ func main() {
if !bytes.Equal(outInterp, outExp) {
t.Errorf("\nGot: %q,\n want: %q", string(outInterp), string(outExp))
}

}

0 comments on commit 3cccd72

Please sign in to comment.