File tree 2 files changed +11
-9
lines changed
2 files changed +11
-9
lines changed Original file line number Diff line number Diff line change 5
5
"testing"
6
6
7
7
"github.com/derekdowling/go-json-spec-handler"
8
+ "github.com/derekdowling/jsh-api"
8
9
. "github.com/smartystreets/goconvey/convey"
9
10
)
10
11
@@ -78,3 +79,13 @@ func TestResponseParsing(t *testing.T) {
78
79
})
79
80
})
80
81
}
82
+
83
+ // not a great for this, would much rather have it in test_util, but it causes an
84
+ // import cycle wit jsh-api
85
+ func testAPI () * jshapi.API {
86
+ resource := jshapi .NewMockResource ("test" , 1 , nil )
87
+ api := jshapi .New ("" , nil )
88
+ api .Add (resource )
89
+
90
+ return api
91
+ }
Original file line number Diff line number Diff line change @@ -6,17 +6,8 @@ import (
6
6
"net/url"
7
7
8
8
"github.com/derekdowling/go-json-spec-handler"
9
- "github.com/derekdowling/jsh-api"
10
9
)
11
10
12
- func testAPI () * jshapi.API {
13
- resource := jshapi .NewMockResource ("test" , 1 , nil )
14
- api := jshapi .New ("" , nil )
15
- api .Add (resource )
16
-
17
- return api
18
- }
19
-
20
11
func mockObjectResponse (object * jsh.Object ) (* http.Response , error ) {
21
12
url := & url.URL {Host : "test" }
22
13
setIDPath (url , object .Type , object .ID )
You can’t perform that action at this time.
0 commit comments