HydraDX-node
HydraDX-node copied to clipboard
CORE_ASSET_ID bug in integration tests
Via Chris from Zeitgeist:
I found another strange thing in these XCM integration tests. You defined your CORE_ASSET_ID to be 0. Then you use your craft_exchange_asset_xcm function to swap HDX for HDX, because GeneralIndex is both zero. This makes no sense at the first glance. I expected to see an exchange swap of two different assets.
https://github.com/galacticcouncil/HydraDX-node/blob/e3821e078bdb72a0416f8aebca21ba4a7a599f64/integration-tests/src/exchange_asset.rs#L61
It is not a bug, as we do reanchoring of those assets when we construct the XCM message. But it is indeed implicit, will refactor it to make the assets more explicit.