MCPcopy Create free account
hub / github.com/facebook/time / TestSetTime

Function TestSetTime

clock/clock_linux_test.go:27–32  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

25)
26
27func TestSetTime(t *testing.T) {
28 tx := &unix.Timex{}
29 setTime(tx, 5*time.Second, 123*time.Nanosecond)
30 require.Equal(t, int64(5*time.Second), tx.Time.Sec)
31 require.Equal(t, int64(123*time.Nanosecond), tx.Time.Usec)
32}
33
34func TestSetTimeNegative(t *testing.T) {
35 tx := &unix.Timex{}

Callers

nothing calls this directly

Calls 1

setTimeFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…