MCPcopy Index your code
hub / github.com/dropbox/godropbox / wrapRequire

Function wrapRequire

container/bitarray/bitarray_test.go:15–19  ·  view source on GitHub ↗

Helper to avoid direct calls to require in hot paths; in go 1.9 and later it becomes very expensive due to querying call stack context on every call.

(t *testing.T, condition bool, msgAndArgs ...interface{})

Source from the content-addressed store, hash-verified

13// Helper to avoid direct calls to require in hot paths; in go 1.9 and later
14// it becomes very expensive due to querying call stack context on every call.
15func wrapRequire(t *testing.T, condition bool, msgAndArgs ...interface{}) {
16 if !condition {
17 require.Fail(t, "Fail", msgAndArgs...)
18 }
19}
20
21func asize(n int) int {
22 sz := n / 64

Callers 9

TestNewFunction · 0.85
randArrayFunction · 0.85
TestIsSetFunction · 0.85
TestOrEqualsFunction · 0.85
TestSetClearFunction · 0.85
TestIsAnySetFunction · 0.85
TestIsAnyClearFunction · 0.85
TestSetRangeFunction · 0.85
TestClearRangeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected