| // Copyright 2012 The Go Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style |
| // license that can be found in the LICENSE file. |
| var toFromBigTests = []string{ |
| "b70e0cb46bb4bf7f321390b94a03c1d356c01122343280d6105c1d21", |
| "706a46d476dcb76798e6046d89474788d164c18032d268fd10704fa6", |
| func p224AlternativeToBig(in *p224FieldElement) *big.Int { |
| for i := uint(0); i < 8; i++ { |
| tmp.SetInt64(int64(in[i])) |
| func TestToFromBig(t *testing.T) { |
| for i, test := range toFromBigTests { |
| n, _ := new(big.Int).SetString(test, 16) |
| t.Errorf("#%d: %x != %x", i, n, m) |
| q := p224AlternativeToBig(&x) |
| t.Errorf("#%d: %x != %x (alternative)", i, n, m) |