mirror of
https://github.com/arnaucube/hermez-node.git
synced 2026-02-08 11:56:46 +01:00
Impls exit endpoints and change pagination to cursor
This commit is contained in:
@@ -213,6 +213,7 @@ func TestTxs(t *testing.T) {
|
||||
|
||||
/*
|
||||
Uncomment once the transaction generation is fixed
|
||||
!! test that batches that forge user L1s !!
|
||||
!! Missing tests to check that historic USD is not set if USDUpdate is too old (24h) !!
|
||||
|
||||
// Generate fake L1 txs
|
||||
@@ -333,9 +334,14 @@ func TestExitTree(t *testing.T) {
|
||||
blocks := setTestBlocks(0, 10)
|
||||
batches := test.GenBatches(nBatches, blocks)
|
||||
err := historyDB.AddBatches(batches)
|
||||
const nTokens = 50
|
||||
tokens := test.GenTokens(nTokens, blocks)
|
||||
assert.NoError(t, historyDB.AddTokens(tokens))
|
||||
assert.NoError(t, err)
|
||||
|
||||
exitTree := test.GenExitTree(nBatches)
|
||||
const nAccounts = 3
|
||||
accs := test.GenAccounts(nAccounts, 0, tokens, nil, nil, batches)
|
||||
assert.NoError(t, historyDB.AddAccounts(accs))
|
||||
exitTree := test.GenExitTree(nBatches, batches, accs)
|
||||
err = historyDB.AddExitTree(exitTree)
|
||||
assert.NoError(t, err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user