Fixed tests
This commit is contained in:
@ -55,7 +55,7 @@ func TestAddInvalidTx(t *testing.T) {
|
||||
func TestRemoveSet(t *testing.T) {
|
||||
pool, _ := setup()
|
||||
tx1 := transaction()
|
||||
pool.pool.Add(tx1)
|
||||
pool.addTx(tx1)
|
||||
pool.RemoveSet(types.Transactions{tx1})
|
||||
if pool.Size() > 0 {
|
||||
t.Error("expected pool size to be 0")
|
||||
@ -65,7 +65,7 @@ func TestRemoveSet(t *testing.T) {
|
||||
func TestRemoveInvalid(t *testing.T) {
|
||||
pool, key := setup()
|
||||
tx1 := transaction()
|
||||
pool.pool.Add(tx1)
|
||||
pool.addTx(tx1)
|
||||
pool.RemoveInvalid(stateQuery{})
|
||||
if pool.Size() > 0 {
|
||||
t.Error("expected pool size to be 0")
|
||||
@ -73,7 +73,7 @@ func TestRemoveInvalid(t *testing.T) {
|
||||
|
||||
tx1.SetNonce(1)
|
||||
tx1.SignECDSA(key)
|
||||
pool.pool.Add(tx1)
|
||||
pool.addTx(tx1)
|
||||
pool.RemoveInvalid(stateQuery{})
|
||||
if pool.Size() != 1 {
|
||||
t.Error("expected pool size to be 1, is", pool.Size())
|
||||
|
Reference in New Issue
Block a user