func (t *ModelTestSuite) SetUpTest(c *C) { memGraph, _ := cayley.NewMemoryGraph() memNg, _ := graph.NewGraph(memGraph) t.nodeGraph, t.tmpDir = testutils.TestInit() t.server = httptest.NewServer(api.NewApi(memNg)) t.client = apiclient.ApiClient{t.server.URL, api.JsonEncoding} }
func (suite *GraphTestSuite) SetUpTest(t *C) { suite.ng, suite.testDir = testutils.TestInit() }
func (suite *ApiTestSuite) SetUpTest(t *C) { suite.ng, suite.testDir = testutils.TestInit() suite.server = httptest.NewServer(api.NewApi(suite.ng)) suite.client = http.DefaultClient }
func (suite *ApiClientTestSuite) SetUpTest(t *C) { suite.ng, suite.testDir = testutils.TestInit() suite.server = httptest.NewServer(api.NewApi(suite.ng)) suite.client = apiclient.ApiClient{suite.server.URL, api.JsonEncoding} }