MCPcopy Create free account
hub / github.com/convox/rack / TestSystemGetError

Function TestSystemGetError

pkg/api/system_test.go:58–66  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

56}
57
58func TestSystemGetError(t *testing.T) {
59 testServer(t, func(c *stdsdk.Client, p *structs.MockProvider) {
60 var s1 *structs.System
61 p.On("SystemGet").Return(nil, fmt.Errorf("err1"))
62 err := c.Get("/system", stdsdk.RequestOptions{}, s1)
63 require.EqualError(t, err, "err1")
64 require.Nil(t, s1)
65 })
66}
67
68func TestSystemLogs(t *testing.T) {
69 testServer(t, func(c *stdsdk.Client, p *structs.MockProvider) {

Callers

nothing calls this directly

Calls 2

testServerFunction · 0.70
GetMethod · 0.65

Tested by

no test coverage detected