difftreelog
test fix pallet presence
in: master
2 files changed
tests/src/pallet-presence.test.tsdiffbeforeafterboth20const requiredPallets = [20const requiredPallets = [21 'balances',21 'balances',22 'common',22 'common',23 'randomnesscollectiveflip',24 'timestamp',23 'timestamp',25 'transactionpayment',24 'transactionpayment',26 'treasury',25 'treasury',98 });97 });9998100 itSub('Required pallets are present', ({helper}) => {99 itSub('Required pallets are present', ({helper}) => {101 expect(helper.fetchAllPalletNames()).to.contain.members([...requiredPallets]);100 expect(helper.fetchAllPalletNames()).to.contain.members([...requiredPallets].sort());102 });101 });103102104 itSub('Governance and consensus pallets are present', ({helper}) => {103 itSub('Governance and consensus pallets are present', ({helper}) => {105 expect(helper.fetchAllPalletNames()).to.contain.members([...consensusPallets]);104 expect(helper.fetchAllPalletNames()).to.contain.members([...consensusPallets].sort());106 });105 });107106108 itSub('No extra pallets are included', ({helper}) => {107 itSub('No extra pallets are included', ({helper}) => {tests/src/util/playgrounds/unique.tsdiffbeforeafterboth736736737 fetchAllPalletNames(): string[] {737 fetchAllPalletNames(): string[] {738 if(this.api === null) throw Error('API not initialized');738 if(this.api === null) throw Error('API not initialized');739 return this.api.runtimeMetadata.asLatest.pallets.map(m => m.name.toString().toLowerCase());739 return this.api.runtimeMetadata.asLatest.pallets.map(m => m.name.toString().toLowerCase()).sort();740 }740 }741741742 fetchMissingPalletNames(requiredPallets: string[]): string[] {742 fetchMissingPalletNames(requiredPallets: string[]): string[] {