mirror of
https://github.com/arnaucube/hermez-node.git
synced 2026-02-07 03:16:45 +01:00
Update AccountCreationAuth & fix auth.HashToSign
- Fix AccountCreationAuth.HashToSign (was using `[]byte("0x...")`, which
uses the bytes of the string. Now uses the bytearray of the compressed
BJJ public key (compatible with js implementation))
- Update AccountCreationAuth to last specification (add to hash
parameters ChainID & HermezAddress)
- Add missing test to AccountCreationAuth
This commit is contained in:
@@ -221,7 +221,7 @@ func TestMain(m *testing.M) {
|
||||
test.WipeDB(l2DB.DB()) // this will clean HistoryDB and L2DB
|
||||
|
||||
// Config (smart contract constants)
|
||||
_config := getConfigTest()
|
||||
_config := getConfigTest(chainID)
|
||||
config = configAPI{
|
||||
RollupConstants: *newRollupConstants(_config.RollupConstants),
|
||||
AuctionConstants: _config.AuctionConstants,
|
||||
@@ -238,7 +238,6 @@ func TestMain(m *testing.M) {
|
||||
sdb,
|
||||
l2DB,
|
||||
&_config,
|
||||
chainID,
|
||||
)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
@@ -423,7 +422,7 @@ func TestMain(m *testing.M) {
|
||||
exits: testExits,
|
||||
poolTxsToSend: poolTxsToSend,
|
||||
poolTxsToReceive: poolTxsToReceive,
|
||||
auths: genTestAuths(test.GenAuths(5)),
|
||||
auths: genTestAuths(test.GenAuths(5, _config.ChainID, _config.HermezAddress)),
|
||||
router: router,
|
||||
bids: testBids,
|
||||
slots: api.genTestSlots(
|
||||
|
||||
Reference in New Issue
Block a user