(t *testing.T)
| 521 | } |
| 522 | |
| 523 | func TestTime(t *testing.T) { |
| 524 | var x time.Time |
| 525 | if *ToTime(x) != x { |
| 526 | t.Errorf("*ToTime(%v)", x) |
| 527 | } |
| 528 | if ToTimeOrNil(x) != nil { |
| 529 | t.Errorf("ToTimeOrNil(%v)", x) |
| 530 | } |
| 531 | if GetTime(nil) != x { |
| 532 | t.Errorf("GetTime(%v)", nil) |
| 533 | } |
| 534 | |
| 535 | x = time.Date(2014, 6, 25, 12, 24, 40, 0, time.UTC) |
| 536 | if *ToTime(x) != x { |
| 537 | t.Errorf("*ToTime(%v)", x) |
| 538 | } |
| 539 | if *ToTimeOrNil(x) != x { |
| 540 | t.Errorf("*ToTimeOrNil(%v)", x) |
| 541 | } |
| 542 | if GetTime(&x) != x { |
| 543 | t.Errorf("GetTime(%v)", &x) |
| 544 | } |
| 545 | } |
| 546 | |
| 547 | func Example() { |
| 548 | const ( |
nothing calls this directly
no test coverage detected
searching dependent graphs…