git.delta.rocks / unique-network / refs/commits / 10173820255a

difftreelog

fix update XCM transfer test

Ilja Khabarov2022-07-11parent: #2e3d152.patch.diff
in: master

1 file changed

modifiedtests/src/xcmTransfer.test.tsdiffbeforeafterboth
31const UNIQUE_CHAIN = 1000;31const UNIQUE_CHAIN = 1000;
32const KARURA_CHAIN = 2000;32const KARURA_CHAIN = 2000;
33const KARURA_PORT = '9946';33const KARURA_PORT = '9946';
34const TRANSFER_AMOUNT = 2000000000000000000000000n;
3435
35describe('Integration test: Exchanging QTZ with Karura', () => {36describe('Integration test: Exchanging QTZ with Karura', () => {
36 let alice: IKeyringPair;37 let alice: IKeyringPair;
113 },114 },
114 },115 },
115 fun: {116 fun: {
116 Fungible: 5000000000,117 Fungible: TRANSFER_AMOUNT,
117 },118 },
118 },119 },
119 ],120 ],
148149
149 await usingApi(async (api) => {150 await usingApi(async (api) => {
150 const destination = {151 const destination = {
151 V0: {152 V1: {
153 parents: 1,
152 X3: [154 interior: {
153 'Parent',155 X2: [
154 {156 {Parachain: UNIQUE_CHAIN},
155 Parachain: UNIQUE_CHAIN,
156 },
157 {157 {AccountId32: {
158 AccountId32: {
159 network: 'Any',158 network: 'Any',
160 id: alice.addressRaw,159 id: alice.addressRaw,
161 },160 }},
162 },
163 ],161 ],
162 },
164 },163 },
165 };164 };
166165
167 const id = {166 const id = {
168 ForeignAsset: 0,167 ForeignAsset: 0,
169 };168 };
170169
171 const amount = 5000000000;170 const amount = TRANSFER_AMOUNT;
172 const destWeight = 50000000;171 const destWeight = 50000000;
173172
174 const tx = api.tx.xTokens.transfer(id, amount, destination, destWeight);173 const tx = api.tx.xTokens.transfer(id, amount, destination, destWeight);