MCPcopy
hub / github.com/ha/doozerd / TestStatWithDir

Function TestStatWithDir

src/pkg/store/store_test.go:403–413  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

401}
402
403func TestStatWithDir(t *testing.T) {
404 st := New()
405 defer close(st.Ops)
406 st.Ops <- Op{1, MustEncodeSet("/x", "a", Clobber)}
407 st.Ops <- Op{2, MustEncodeSet("/y", "b", Clobber)}
408 sync(st, 2)
409
410 ln, rev := st.Stat("/")
411 assert.Equal(t, Dir, rev)
412 assert.Equal(t, int32(2), ln)
413}
414
415func TestStatWithFile(t *testing.T) {
416 st := New()

Callers

nothing calls this directly

Calls 4

NewFunction · 0.85
MustEncodeSetFunction · 0.85
syncFunction · 0.85
StatMethod · 0.65

Tested by

no test coverage detected