(t *testing.T)
| 542 | } |
| 543 | |
| 544 | func TestRandPool(t *testing.T) { |
| 545 | myString := "8059ddhdle77cb52" |
| 546 | EnableRandPool() |
| 547 | SetRand(strings.NewReader(myString)) |
| 548 | _, err := NewRandom() |
| 549 | if err == nil { |
| 550 | t.Errorf("expecting an error as reader has no more bytes") |
| 551 | } |
| 552 | DisableRandPool() |
| 553 | SetRand(strings.NewReader(myString)) |
| 554 | _, err = NewRandom() |
| 555 | if err != nil { |
| 556 | t.Errorf("failed generating UUID from a reader") |
| 557 | } |
| 558 | } |
| 559 | |
| 560 | func TestWrongLength(t *testing.T) { |
| 561 | _, err := Parse("12345") |
nothing calls this directly
no test coverage detected