Skip to content

Commit

Permalink
move block to a new package (#401)
Browse files Browse the repository at this point in the history
move block to a new package
  • Loading branch information
Yutong Pei authored Jan 3, 2019
1 parent f277f6f commit 4321e91
Show file tree
Hide file tree
Showing 39 changed files with 1,419 additions and 943 deletions.
4 changes: 2 additions & 2 deletions accounts/keystore/accountmanager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

"github.com/iotexproject/iotex-core/action"
"github.com/iotexproject/iotex-core/address"
"github.com/iotexproject/iotex-core/blockchain"
"github.com/iotexproject/iotex-core/blockchain/block"
"github.com/iotexproject/iotex-core/pkg/hash"
"github.com/iotexproject/iotex-core/pkg/keypair"
"github.com/iotexproject/iotex-core/test/testaddress"
Expand Down Expand Up @@ -150,7 +150,7 @@ func TestAccountManager_SignHash(t *testing.T) {

pk, err := keypair.DecodePublicKey(pubKey1)
require.NoError(err)
blk := blockchain.NewBlock(1, 0, hash.ZeroHash32B, testutil.TimestampNow(), pk, nil)
blk := block.NewBlockDeprecated(1, 0, hash.ZeroHash32B, testutil.TimestampNow(), pk, nil)
hash := blk.HashBlock()

signature, err := m.SignHash(rawAddr1, hash[:])
Expand Down
4 changes: 2 additions & 2 deletions accounts/keystore/single_accountmanager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

"github.com/iotexproject/iotex-core/action"
"github.com/iotexproject/iotex-core/address"
"github.com/iotexproject/iotex-core/blockchain"
"github.com/iotexproject/iotex-core/blockchain/block"
"github.com/iotexproject/iotex-core/pkg/hash"
"github.com/iotexproject/iotex-core/pkg/keypair"
"github.com/iotexproject/iotex-core/testutil"
Expand Down Expand Up @@ -108,7 +108,7 @@ func TestSingleAccountManager_SignHash(t *testing.T) {

pk, err := keypair.DecodePublicKey(pubKey1)
require.NoError(err)
blk := blockchain.NewBlock(1, 0, hash.ZeroHash32B, testutil.TimestampNow(), pk, nil)
blk := block.NewBlockDeprecated(1, 0, hash.ZeroHash32B, testutil.TimestampNow(), pk, nil)
hash := blk.HashBlock()
signature, err := m.SignHash(hash[:])
require.NoError(err)
Expand Down
Loading

0 comments on commit 4321e91

Please sign in to comment.