File tree Expand file tree Collapse file tree 1 file changed +17
-16
lines changed
Expand file tree Collapse file tree 1 file changed +17
-16
lines changed Original file line number Diff line number Diff line change @@ -5,22 +5,23 @@ import (
55 "testing"
66)
77
8- // func TestEnv_Path_notOpen(t *testing.T) {
9- // env, err := NewEnv()
10- // if err != nil {
11- // t.Fatalf("create: %v", err)
12- // }
13- // defer env.Close()
14- //
15- // // before Open the Path method returns "" and a non-nil error.
16- // path, err := env.Path()
17- // if err == nil {
18- // t.Errorf("no error returned before Open")
19- // }
20- // if path != "" {
21- // t.Errorf("non-zero path returned before Open")
22- // }
23- // }
8+ func TestEnv_Path_notOpen (t * testing.T ) {
9+ env , err := NewEnv (Default )
10+ if err != nil {
11+ t .Fatalf ("create: %v" , err )
12+ }
13+ defer env .Close ()
14+
15+ // before Open the Path method returns "" and a non-nil error.
16+ path , err := env .Path ()
17+ if err == nil {
18+ t .Errorf ("no error returned before Open" )
19+ }
20+ if path != "" {
21+ t .Errorf ("non-zero path returned before Open" )
22+ }
23+ }
24+
2425func TestEnv_Path (t * testing.T ) {
2526 env , err := NewEnv (Default )
2627 if err != nil {
You can’t perform that action at this time.
0 commit comments