package broker import ( "local/truckstop/config" "os" "testing" "time" ) func TestWorkingHoursNTG(t *testing.T) { os.Setenv("CONFIG", "../config.json") if err := config.Refresh(nil); err != nil { t.Fatal(err) } ntg := NTGVision{} if !ntg.workingHours(time.Date(2022, 1, 27, 12, 0, 0, 0, time.FixedZone("MST", -7*60*60))) { t.Fatal("noon MST not ok") } if ntg.workingHours(time.Date(2022, 1, 27, 23, 0, 0, 0, time.FixedZone("MST", -7*60*60))) { t.Fatal("midnight MST ok") } }