MCPcopy Create free account
hub / github.com/cli/cli / testingPortsApp

Function testingPortsApp

pkg/cmd/codespace/ports_test.go:167–185  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

165}
166
167func testingPortsApp() *App {
168 disabledCodespace := &api.Codespace{
169 Name: "disabledCodespace",
170 PendingOperation: true,
171 PendingOperationDisabledReason: "Some pending operation",
172 }
173 apiMock := &apiClientMock{
174 GetCodespaceFunc: func(_ context.Context, name string, _ bool) (*api.Codespace, error) {
175 if name == "disabledCodespace" {
176 return disabledCodespace, nil
177 }
178 return nil, nil
179 },
180 }
181
182 ios, _, _, _ := iostreams.Test()
183
184 return NewApp(ios, nil, apiMock, nil, nil)
185}

Calls 2

TestFunction · 0.92
NewAppFunction · 0.85

Tested by

no test coverage detected