summaryrefslogtreecommitdiff
path: root/src/pkg/big/int_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/pkg/big/int_test.go')
-rw-r--r--[-rwxr-xr-x]src/pkg/big/int_test.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/pkg/big/int_test.go b/src/pkg/big/int_test.go
index 03446d6ae..b2e169217 100755..100644
--- a/src/pkg/big/int_test.go
+++ b/src/pkg/big/int_test.go
@@ -301,6 +301,9 @@ func TestGetString(t *testing.T) {
func TestSetString(t *testing.T) {
tmp := new(Int)
for i, test := range stringTests {
+ // initialize to a non-zero value so that issues with parsing
+ // 0 are detected
+ tmp.SetInt64(1234567890)
n1, ok1 := new(Int).SetString(test.in, test.base)
n2, ok2 := tmp.SetString(test.in, test.base)
expected := NewInt(test.val)