MCPcopy
hub / github.com/cortexlabs/cortex / TestPackUnpack

Function TestPackUnpack

pkg/proxy/breaker_test.go:328–337  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

326}
327
328func TestPackUnpack(t *testing.T) {
329 wantL := uint64(256)
330 wantR := uint64(513)
331
332 gotL, gotR := unpack(pack(wantL, wantR))
333
334 if gotL != wantL || gotR != wantR {
335 t.Fatalf("Got %d, %d want %d, %d", gotL, gotR, wantL, wantR)
336 }
337}
338
339func tryAcquire(sem *semaphore, gotChan chan struct{}) {
340 go func() {

Callers

nothing calls this directly

Calls 2

unpackFunction · 0.85
packFunction · 0.85

Tested by

no test coverage detected