(t *testing.T)
| 154 | } |
| 155 | |
| 156 | func TestConstants(t *testing.T) { |
| 157 | for x, tt := range constants { |
| 158 | v, ok := tt.c.(fmt.Stringer) |
| 159 | if !ok { |
| 160 | t.Errorf("%x: %v: not a stringer", x, v) |
| 161 | } else if s := v.String(); s != tt.name { |
| 162 | v, _ := tt.c.(int) |
| 163 | t.Errorf("%x: Constant %T:%d gives %q, expected %q", x, tt.c, v, s, tt.name) |
| 164 | } |
| 165 | } |
| 166 | } |
| 167 | |
| 168 | func TestRandomUUID(t *testing.T) { |
| 169 | m := make(map[string]bool) |