Skip to content

Commit

Permalink
Feat: add HDX routes between Interlay and HydraDX (#126)
Browse files Browse the repository at this point in the history
* feat: add HDX route between Interlay and HydraDX

* test: add HDX to interlay spec

* chore: add top level skip for interlay.spec.ts
  • Loading branch information
bvotteler committed Apr 12, 2024
1 parent 86e836c commit ad94b14
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
5 changes: 5 additions & 0 deletions src/adapters/hydradx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,11 @@ export const hydradxRoutersConfig = createRouteConfigs("hydradx", [
fee: { token: "WBTC", amount: "4" },
},
},
{
to: "interlay",
token: "HDX",
xcm: { fee: { token: "HDX", amount: "500000000000" } },
},
{
to: "interlay",
token: "IBTC",
Expand Down
3 changes: 2 additions & 1 deletion src/adapters/interlay.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { BifrostAdapter, BifrostPolkadotAdapter } from "./bifrost";
import { HydraDxAdapter } from "./hydradx";
import { AstarAdapter } from "./astar";

describe("Interlay/Kintsugi connections tests", () => {
describe.skip("Interlay/Kintsugi connections tests", () => {
jest.setTimeout(30000);

const provider = new ApiProvider();
Expand Down Expand Up @@ -160,6 +160,7 @@ describe("Interlay/Kintsugi connections tests", () => {
printBidirectionalTxs("interlay", "assetHubPolkadot", "USDT");
printBidirectionalTxs("interlay", "hydradx", "IBTC");
printBidirectionalTxs("interlay", "hydradx", "INTR");
printBidirectionalTxs("interlay", "hydradx", "HDX");
printBidirectionalTxs("interlay", "acala", "INTR");
printBidirectionalTxs("interlay", "acala", "IBTC");
printBidirectionalTxs("interlay", "parallel", "INTR");
Expand Down
14 changes: 14 additions & 0 deletions src/adapters/interlay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,13 @@ export const interlayRouteConfigs = createRouteConfigs("interlay", [
weightLimit: DEST_WEIGHT,
},
},
{
to: "hydradx",
token: "HDX",
xcm: {
fee: { token: "HDX", amount: "100000000000" },
},
},
{
to: "bifrostPolkadot",
token: "VDOT",
Expand Down Expand Up @@ -194,6 +201,13 @@ export const interlayTokensConfig: Record<
ed: "0",
toRaw: () => ({ ForeignAsset: 12 }),
},
HDX: {
name: "HDX",
symbol: "HDX",
decimals: 12,
ed: "0",
toRaw: () => ({ ForeignAsset: 13 }),
},
USDT: {
name: "USDT",
symbol: "USDT",
Expand Down

0 comments on commit ad94b14

Please sign in to comment.