Source file src/crypto/ecdsa/ecdsa_s390x_test.go

     1  // Copyright 2020 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  //go:build s390x
     6  
     7  package ecdsa
     8  
     9  import (
    10  	"crypto/elliptic"
    11  	"testing"
    12  )
    13  
    14  func TestNoAsm(t *testing.T) {
    15  	testingDisableKDSA = true
    16  	defer func() { testingDisableKDSA = false }()
    17  
    18  	curves := [...]elliptic.Curve{
    19  		elliptic.P256(),
    20  		elliptic.P384(),
    21  		elliptic.P521(),
    22  	}
    23  
    24  	for _, curve := range curves {
    25  		name := curve.Params().Name
    26  		t.Run(name, func(t *testing.T) { testKeyGeneration(t, curve) })
    27  		t.Run(name, func(t *testing.T) { testSignAndVerify(t, curve) })
    28  		t.Run(name, func(t *testing.T) { testNonceSafety(t, curve) })
    29  		t.Run(name, func(t *testing.T) { testINDCCA(t, curve) })
    30  		t.Run(name, func(t *testing.T) { testNegativeInputs(t, curve) })
    31  	}
    32  }
    33  

View as plain text