aboutsummaryrefslogtreecommitdiffstats
path: root/test/keygen.go
diff options
context:
space:
mode:
authorWei-Ning Huang <w@dexon.org>2018-10-20 12:57:05 +0800
committerWei-Ning Huang <w@dexon.org>2019-04-09 21:32:50 +0800
commitfcfa850fca2d7fb22e063eb5b859aa0d656dd9bd (patch)
tree896caaa0dfea0e39a8b51aea6b9bec4e336ca87e /test/keygen.go
parent0cf107b225f25602527ddda3f1897f182ebb205a (diff)
downloaddexon-fcfa850fca2d7fb22e063eb5b859aa0d656dd9bd.tar.gz
dexon-fcfa850fca2d7fb22e063eb5b859aa0d656dd9bd.tar.zst
dexon-fcfa850fca2d7fb22e063eb5b859aa0d656dd9bd.zip
test: update run_test.sh
Diffstat (limited to 'test/keygen.go')
-rw-r--r--test/keygen.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/keygen.go b/test/keygen.go
index 986342368..5397bc269 100644
--- a/test/keygen.go
+++ b/test/keygen.go
@@ -3,12 +3,18 @@ package main
import (
"encoding/hex"
"fmt"
+ "os"
+ "strconv"
"github.com/dexon-foundation/dexon/crypto"
)
func main() {
- for i := 0; i < 4; i++ {
+ count, err := strconv.Atoi(os.Args[1])
+ if err != nil {
+ panic(err)
+ }
+ for i := 0; i < count; i++ {
privKey, err := crypto.GenerateKey()
if err != nil {
panic(err)