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

difftreelog

Merge pull request #5 from usetech-llc/feature/NFTPAR-90

usetech-llc2020-10-07parents: #bfa69d5 #dfe5511.patch.diff
in: master
Feature/nftpar-90

1 file changed

addedtests/src/pallet-presence.test.tsdiffbeforeafterboth
after · tests/src/pallet-presence.test.ts
1import { ApiPromise } from "@polkadot/api";2import { expect } from "chai";3import usingApi from "./substrate/substrate-api";45function getModuleNames(api: ApiPromise): string[] {6  return api.runtimeMetadata.asLatest.modules.map(m => m.name.toString().toLowerCase());7}89describe('Pallet presence.', () => {10  it('NFT pallet is present.', async () => {11    await usingApi(async api => {12      expect(getModuleNames(api)).to.include('nft');13    });14  });15  it('Balances pallet is present.', async () => {16    await usingApi(async api => {17      expect(getModuleNames(api)).to.include('balances');18    });19  });20  it('Contracts pallet is present.', async () => {21    await usingApi(async api => {22      expect(getModuleNames(api)).to.include('contracts');23    });24  });25});