status-go/services/wallet/thirdparty/mercuryo/request_currencies_test.go
dlipicar b9d083c6d5
feat(wallet): add split onramp url endpoint (#5656)
* feat(wallet)_: add split onramp url endpoint & fix onrmap url
2024-08-12 12:53:32 +00:00

37 lines
645 B
Go

package mercuryo
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestUnmarshallCurrencies(t *testing.T) {
requiredAssetIDs := []CryptoCurrency{
{
Network: "ETHEREUM",
Symbol: "ETH",
Contract: "",
},
{
Network: "OPTIMISM",
Symbol: "ETH",
Contract: "",
},
{
Network: "ARBITRUM",
Symbol: "ETH",
Contract: "",
},
{
Network: "ETHEREUM",
Symbol: "DAI",
Contract: "0x6b175474e89094c44da98b954eedeac495271d0f",
},
}
currencies, err := handleCurrenciesResponse(getTestCurrenciesOKResponse())
assert.NoError(t, err)
assert.Subset(t, currencies, requiredAssetIDs)
}