Skip to content

Commit

Permalink
fix(AccountsAssets): historicApi for AccountsAssets, bug fixes, error…
Browse files Browse the repository at this point in the history
… handling, e2e-tests (#721)

* switch asset service to historicApi

* fix: bug

* throw appropriate error for missing pallet

* lint

* asset-balance e2e tests for statemint

* add more tests for asset balances

* e2e for statemine

* lint

* Update src/services/accounts/AccountsAssetsService.ts

Co-authored-by: David <dvdplm@gmail.com>

* adjust the returned error when assets pallets doesnt exist

* fix comment

Co-authored-by: David <dvdplm@gmail.com>
  • Loading branch information
TarikGul and dvdplm committed Oct 26, 2021
1 parent 8cfe930 commit 583936d
Show file tree
Hide file tree
Showing 21 changed files with 2,109 additions and 16 deletions.
2 changes: 2 additions & 0 deletions e2e-tests/endpoints/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import { IChains } from '../types';
import { kusamaEndpoints } from './kusama';
import { polkadotEndpoints } from './polkadot';
import { statemineEndpoints } from './statemine';
import { westendEndpoints } from './westend';

export const endpoints: IChains = {
kusama: kusamaEndpoints,
polkadot: polkadotEndpoints,
westend: westendEndpoints,
statemine: statemineEndpoints,
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"at": {
"hash": "0x1f09372636107591e983dc1234fd27dc5d2bb463c5ed5e8bf62fefbad65df758",
"height": "993480"
},
"amount": null,
"deposit": null
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import accountsApprovals993480 from './993480.json';

export const statemineAccountsApprovalsEndpoints = [
[
'/accounts/CwqsPsimisa33niBsKd513TBne4PnTHvfhyLR6Vh73DBQMY/asset-approvals?assetId=100&delegate=CwqsPsimisa33niBsKd513TBne4PnTHvfhyLR6Vh73DBQMY&at=993480',
JSON.stringify(accountsApprovals993480),
],
];
Loading

0 comments on commit 583936d

Please sign in to comment.