MCPcopy Index your code
hub / github.com/dnote/dnote / truncateMicro

Function truncateMicro

pkg/server/controllers/books_test.go:36–38  ·  view source on GitHub ↗

truncateMicro rounds time to microsecond precision to match SQLite storage

(t time.Time)

Source from the content-addressed store, hash-verified

34
35// truncateMicro rounds time to microsecond precision to match SQLite storage
36func truncateMicro(t time.Time) time.Time {
37 return t.Round(time.Microsecond)
38}
39
40func TestGetBooks(t *testing.T) {
41 db := testutils.InitMemoryDB(t)

Callers 5

getExpectedNotePayloadFunction · 0.85
TestGetBooksFunction · 0.85
TestGetBooksByNameFunction · 0.85
TestGetBookFunction · 0.85
TestCreateBookFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected