git.delta.rocks / unique-network / refs/commits / 5af2b45e48fe

difftreelog

Tests cleanup

Greg Zaitsev2021-07-14parent: #2fc9e2d.patch.diff
in: master

3 files changed

modifiedtests/src/pallet-presence.test.tsdiffbeforeafterboth
42 'auraext'42 'auraext'
43];43];
4444
45describe.only('Pallet presence', () => {45describe('Pallet presence', () => {
46 it('Required pallets are present', async () => {46 it('Required pallets are present', async () => {
47 await usingApi(async api => {47 await usingApi(async api => {
48 for (let i=0; i<requiredPallets.length; i++) {48 for (let i=0; i<requiredPallets.length; i++) {
modifiedtests/src/removeCollectionAdmin.test.tsdiffbeforeafterboth
20 const Alice = privateKey('//Alice');20 const Alice = privateKey('//Alice');
21 const Bob = privateKey('//Bob');21 const Bob = privateKey('//Bob');
22 const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON();22 const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON();
23 expect(collection.Owner).to.be.deep.eq(normalizeAccountId(Alice.address));23 expect(collection.Owner).to.be.deep.eq(Alice.address);
24 // first - add collection admin Bob24 // first - add collection admin Bob
25 const addAdminTx = api.tx.nft.addCollectionAdmin(collectionId, normalizeAccountId(Bob.address));25 const addAdminTx = api.tx.nft.addCollectionAdmin(collectionId, normalizeAccountId(Bob.address));
26 await submitTransactionAsync(Alice, addAdminTx);26 await submitTransactionAsync(Alice, addAdminTx);
modifiedtests/src/removeCollectionSponsor.test.tsdiffbeforeafterboth
28let alice: IKeyringPair;28let alice: IKeyringPair;
29let bob: IKeyringPair;29let bob: IKeyringPair;
3030
31describe('integration test: ext. removeCollectionSponsor():', () => {31describe.only('integration test: ext. removeCollectionSponsor():', () => {
3232
33 before(async () => {33 before(async () => {
34 await usingApi(async () => {34 await usingApi(async () => {
38 });38 });
39 });39 });
4040
41 it('Remove NFT collection sponsor stops sponsorship', async () => {41 it('Removing NFT collection sponsor stops sponsorship', async () => {
42 const collectionId = await createCollectionExpectSuccess();42 const collectionId = await createCollectionExpectSuccess();
43 await setCollectionSponsorExpectSuccess(collectionId, bob.address);43 await setCollectionSponsorExpectSuccess(collectionId, bob.address);
44 await confirmSponsorshipExpectSuccess(collectionId, '//Bob');44 await confirmSponsorshipExpectSuccess(collectionId, '//Bob');
8585
86});86});
8787
88describe('(!negative test!) integration test: ext. removeCollectionSponsor():', () => {88describe.only('(!negative test!) integration test: ext. removeCollectionSponsor():', () => {
89 before(async () => {89 before(async () => {
90 await usingApi(async () => {90 await usingApi(async () => {
91 const keyring = new Keyring({ type: 'sr25519' });91 const keyring = new Keyring({ type: 'sr25519' });