@@ -39,7 +39,8 @@ func Test_MayanExplorer_GetSwap(t *testing.T) {
3939 "redeemRelayerFee": "0.1",
4040 "refundRelayerFee": "0.05",
4141 "trader": "0xTrader",
42- "minAmountOut64": "100"
42+ "minAmountOut64": "100",
43+ "sourceTxHash": "0xhash"
4344 }` ),
4445 statusCode : http .StatusOK ,
4546 wantResult : & mayan.MayanSwap {
@@ -51,6 +52,7 @@ func Test_MayanExplorer_GetSwap(t *testing.T) {
5152 RefundRelayerFee : "0.05" ,
5253 Trader : "0xTrader" ,
5354 MinAmountOut64 : "100" ,
55+ SourceTxHash : "0xhash" ,
5456 },
5557 },
5658 {
@@ -80,7 +82,7 @@ func Test_MayanExplorer_GetSwap(t *testing.T) {
8082 client := mayan .NewMayanExplorer ()
8183 client .HTTPClient .Transport = roundTripperFunc (func (req * http.Request ) (* http.Response , error ) {
8284 // Verify URL construction
83- expectedURL := fmt .Sprintf ("%s/v3/swap/trx/ %s" , mayan .MAYAN_EXPLORER_URL , tc .hash )
85+ expectedURL := fmt .Sprintf ("%s/v3/swap/order-id/SWIFT_ %s" , mayan .MAYAN_EXPLORER_URL , tc .hash )
8486 if req .URL .String () != expectedURL {
8587 return nil , fmt .Errorf ("unexpected URL: got %s, want %s" , req .URL .String (), expectedURL )
8688 }
0 commit comments