Query the system status https://maze.io/system.v0
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

uptime_test.go 356B

12345678910111213141516171819202122
  1. package system
  2. import (
  3. "testing"
  4. "time"
  5. )
  6. func TestBootTime(t *testing.T) {
  7. var null time.Time
  8. if null.Equal(kernel.bootTime) {
  9. t.Fatal("bootTime not set")
  10. }
  11. t.Logf("booted %s", BootTime())
  12. }
  13. func TestUptime(t *testing.T) {
  14. var null time.Time
  15. if null.Equal(kernel.bootTime) {
  16. t.Fatal("bootTime not set")
  17. }
  18. t.Logf("uptime %s", Uptime())
  19. }