-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(solver/app): approve outbox spend in fulfil (#2572)
Before submitting fulfil to outbox, approve it to spend token prereqs. issue: #2571 --------- Co-authored-by: Kevin Halliday <[email protected]>
- Loading branch information
Showing
16 changed files
with
454 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package devapp | ||
|
||
import ( | ||
"math/big" | ||
"testing" | ||
|
||
"github.com/ethereum/go-ethereum/common" | ||
|
||
"github.com/stretchr/testify/require" | ||
) | ||
|
||
func TestPackUnpack(t *testing.T) { | ||
t.Parallel() | ||
|
||
dep := DepositArgs{ | ||
OnBehalfOf: common.Address{}, | ||
Amount: big.NewInt(1), | ||
} | ||
|
||
packed, err := packDeposit(dep) | ||
require.NoError(t, err) | ||
|
||
dep2, err := unpackDeposit(packed) | ||
require.NoError(t, err) | ||
|
||
require.Equal(t, dep, dep2) | ||
} |
Oops, something went wrong.