git.delta.rocks / unique-network / refs/commits / 6ca971af28d8

difftreelog

test return missing generateKeyringPair

Yaroslav Bolyukin2022-09-16parent: #3d41009.patch.diff
in: master

1 file changed

modifiedtests/src/util/helpers.tsdiffbeforeafterboth
1853itApi.only = (name: string, cb: (apis: { api: ApiPromise, privateKeyWrapper: (account: string) => IKeyringPair }) => any) => itApi(name, cb, {only: true});1853itApi.only = (name: string, cb: (apis: { api: ApiPromise, privateKeyWrapper: (account: string) => IKeyringPair }) => any) => itApi(name, cb, {only: true});
1854itApi.skip = (name: string, cb: (apis: { api: ApiPromise, privateKeyWrapper: (account: string) => IKeyringPair }) => any) => itApi(name, cb, {skip: true});1854itApi.skip = (name: string, cb: (apis: { api: ApiPromise, privateKeyWrapper: (account: string) => IKeyringPair }) => any) => itApi(name, cb, {skip: true});
18551855
1856let accountSeed = 10000;
1857export function generateKeyringPair(keyring: Keyring) {
1858 const privateKey = `0xDEADBEEF${(Date.now() + (accountSeed++)).toString(16)}`.padStart(64, '0');
1859 return keyring.addFromUri(privateKey);
1860}
18561861
1857export async function expectSubstrateEventsAtBlock(api: ApiPromise, blockNumber: AnyNumber | BlockNumber, section: string, methods: string[], dryRun = false) {1862export async function expectSubstrateEventsAtBlock(api: ApiPromise, blockNumber: AnyNumber | BlockNumber, section: string, methods: string[], dryRun = false) {
1858 const blockHash = await api.rpc.chain.getBlockHash(blockNumber);1863 const blockHash = await api.rpc.chain.getBlockHash(blockNumber);