MCPcopy Index your code
hub / github.com/google/go-github / TestUpdateGo

Function TestUpdateGo

tools/metadata/main_test.go:29–52  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

27)
28
29func TestUpdateGo(t *testing.T) {
30 t.Parallel()
31 t.Run("valid", func(t *testing.T) {
32 t.Parallel()
33 res := runTest(t, "testdata/update-go/valid", "update-go")
34 res.assertOutput("", "")
35 res.assertNoErr()
36 res.checkGolden()
37 })
38
39 t.Run("invalid", func(t *testing.T) {
40 t.Parallel()
41 res := runTest(t, "testdata/update-go/invalid", "update-go")
42 res.assertOutput("", "")
43 res.assertErr(`
44no operations defined for AService.NoOperation
45no operations defined for AService.NoComment
46ambiguous operation "GET /ambiguous/{}" could match any of: [GET /ambiguous/{id} GET /ambiguous/{name}]
47could not find operation "GET /missing/{id}" in openapi_operations.yaml
48duplicate operation: GET /a/{a_id}
49`)
50 res.checkGolden()
51 })
52}
53
54func TestUnused(t *testing.T) {
55 t.Parallel()

Callers

nothing calls this directly

Calls 6

runTestFunction · 0.85
assertOutputMethod · 0.80
assertNoErrMethod · 0.80
checkGoldenMethod · 0.80
assertErrMethod · 0.80
RunMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…