core: unify verifyTxAttributes errors

We already have pretty ErrInvalidAttribute error, so I think that all
other `verifyTxAttributes` errors should be wrappers around ErrInvalidAttr.
This commit is contained in:
Anna Shaleva 2020-11-20 13:25:19 +03:00
parent 31aa66a4a4
commit 8cdf2d3464
2 changed files with 6 additions and 7 deletions

View file

@ -621,7 +621,7 @@ func TestVerifyTx(t *testing.T) {
bc.config.P2PSigExtensions = true
t.Run("NotYetValid", func(t *testing.T) {
tx := getNVBTx(bc.blockHeight + 1)
require.True(t, errors.Is(bc.VerifyTx(tx), ErrTxNotYetValid))
require.True(t, errors.Is(bc.VerifyTx(tx), ErrInvalidAttribute))
})
t.Run("positive", func(t *testing.T) {
tx := getNVBTx(bc.blockHeight)