MCPcopy Index your code
hub / github.com/maruel/panicparse / TestCallPkg

Function TestCallPkg

stack/stack_test.go:81–229  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

79}
80
81func TestCallPkg(t *testing.T) {
82 t.Parallel()
83 data := []struct {
84 name string
85 f string
86 s string
87 // Expectations
88 DirSrc string
89 SrcName string
90 LocalSrcPath string
91 RelSrcPath string
92 ImportPath string
93 Location Location
94 }{
95 {
96 name: "Pkg",
97 f: "gopkg.in/yaml%2ev2.handleErr",
98 s: "/gpremote/src/gopkg.in/yaml.v2/yaml.go",
99 DirSrc: pathJoin("yaml.v2", "yaml.go"),
100 SrcName: "yaml.go",
101 LocalSrcPath: "/gplocal/src/gopkg.in/yaml.v2/yaml.go",
102 RelSrcPath: "gopkg.in/yaml.v2/yaml.go",
103 ImportPath: "gopkg.in/yaml.v2",
104 Location: GOPATH,
105 },
106 {
107 name: "PkgMod",
108 f: "gopkg.in/yaml%2ev2.handleErr",
109 s: "/gpremote/pkg/mod/gopkg.in/yaml.v2@v2.3.0/yaml.go",
110 DirSrc: pathJoin("yaml.v2@v2.3.0", "yaml.go"),
111 SrcName: "yaml.go",
112 LocalSrcPath: "/gplocal/pkg/mod/gopkg.in/yaml.v2@v2.3.0/yaml.go",
113 RelSrcPath: "gopkg.in/yaml.v2@v2.3.0/yaml.go",
114 ImportPath: "gopkg.in/yaml.v2@v2.3.0",
115 Location: GoPkg,
116 },
117 {
118 name: "PkgMethod",
119 f: "gopkg.in/yaml%2ev2.(*decoder).unmarshal",
120 s: "/gpremote/src/gopkg.in/yaml.v2/yaml.go",
121 DirSrc: pathJoin("yaml.v2", "yaml.go"),
122 SrcName: "yaml.go",
123 LocalSrcPath: "/gplocal/src/gopkg.in/yaml.v2/yaml.go",
124 RelSrcPath: "gopkg.in/yaml.v2/yaml.go",
125 ImportPath: "gopkg.in/yaml.v2",
126 Location: GOPATH,
127 },
128 {
129 name: "Stdlib",
130 f: "reflect.Value.assignTo",
131 s: "/grremote/src/reflect/value.go",
132 DirSrc: pathJoin("reflect", "value.go"),
133 SrcName: "value.go",
134 LocalSrcPath: "/grlocal/src/reflect/value.go",
135 RelSrcPath: "reflect/value.go",
136 ImportPath: "reflect",
137 Location: Stdlib,
138 },

Callers

nothing calls this directly

Calls 4

pathJoinFunction · 0.85
newCallFunction · 0.85
compareStringFunction · 0.70
updateLocationsMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…