Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/bracesdev/errtrace
/ wrapExisting
Function
wrapExisting
wrap_caller_test.go:43–45 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
41
var
errFoo = errors.New(
"foo"
)
42
43
func
wrapExisting() error {
44
return
errtrace.GetCaller().Wrap(errFoo)
45
}
46
47
func
TestGetCallerWrap_PassCaller(t *testing.T) {
48
err := callPassCaller()
Callers
1
callWrapExisting
Function · 0.85
Calls
2
GetCaller
Function · 0.92
Wrap
Method · 0.80
Tested by
no test coverage detected