(t *testing.T)
| 222 | } |
| 223 | |
| 224 | func TestTupleHashXOFNISTSample4(t *testing.T) { |
| 225 | outputLength := 64 |
| 226 | tuples := [][]byte{ |
| 227 | []byte{0x00, 0x01, 0x02}, |
| 228 | []byte{0x10, 0x11, 0x12, 0x13, 0x14, 0x15}, |
| 229 | } |
| 230 | S := []byte{} |
| 231 | h := TupleHashXOF256(tuples, S) |
| 232 | output := make([]byte, outputLength) |
| 233 | h.Read(output) |
| 234 | expected := strings.Replace("03 DE D4 61 0E D6 45 0A 1E 3F 8B C4 49 51 D1 4F BC 38 4A B0 EF E5 7B 00 0D F6 B6 DF 5A AE 7C D5 68 E7 73 77 DA F1 3F 37 EC 75 CF 5F C5 98 B6 84 1D 51 DD 20 7C 99 1C D4 5D 21 0B A6 0A C5 2E B9", " ", "", -1) |
| 235 | if got := strings.ToUpper(hex.EncodeToString(output)); got != expected { |
| 236 | t.Errorf("TestTupleHashXOFNISTSample4: got %s, want %s", got, expected) |
| 237 | } |
| 238 | } |
| 239 | |
| 240 | func TestTupleHashXOFNISTSample5(t *testing.T) { |
| 241 | outputLength := 64 |
nothing calls this directly
no test coverage detected