Skip to content

Commit

Permalink
Merge branch 'develop' into 17848-nft-dropdowns
Browse files Browse the repository at this point in the history
  • Loading branch information
tmashuang authored Mar 6, 2023
2 parents d2988a3 + c8e8db2 commit 2f918bf
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
9 changes: 5 additions & 4 deletions test/e2e/nft/import-erc1155.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ describe('Import ERC1155 NFT', function () {
await driver.fill('[data-testid="token-id"]', '1');
await driver.clickElement({ text: 'Add', tag: 'button' });

const newNftNotification = await driver.findElement({
const newNftNotification = await driver.findVisibleElement({
text: 'NFT was successfully added!',
tag: 'h6',
});
Expand All @@ -53,10 +53,11 @@ describe('Import ERC1155 NFT', function () {
css: 'h5',
text: 'Rocks',
});
const importedERC1155Image = await driver.waitForSelector(
'[class="nfts-items__item-image"]',
);
assert.equal(await importedERC1155.isDisplayed(), true);

const importedERC1155Image = await driver.findVisibleElement(
'.nfts-items__item img',
);
assert.equal(await importedERC1155Image.isDisplayed(), true);
},
);
Expand Down
7 changes: 5 additions & 2 deletions test/e2e/nft/remove-erc1155.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,11 @@ describe('Remove ERC1155 NFT', function () {
await driver.fill('[data-testid="token-id"]', '1');
await driver.clickElement({ text: 'Add', tag: 'button' });

// Open the details and click remove nft button
await driver.clickElement('.nfts-items__item-image');
// Open the details page and click remove nft button
const importedNftImage = await driver.findVisibleElement(
'.nfts-items__item img',
);
await importedNftImage.click();
await driver.clickElement('[data-testid="nft-options__button"]');
await driver.clickElement('[data-testid="nft-item-remove"]');

Expand Down
5 changes: 4 additions & 1 deletion test/e2e/nft/view-erc1155-details.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,10 @@ describe('View ERC1155 NFT details', function () {
await driver.clickElement({ text: 'Add', tag: 'button' });

// Click to open the NFT details page and check displayed account
await driver.clickElement('.nfts-items__item-image');
const importedNftImage = await driver.findVisibleElement(
'.nfts-items__item img',
);
await importedNftImage.click();
const detailsPageAccount = await driver.findElement(
'.asset-breadcrumb span:nth-of-type(2)',
);
Expand Down

0 comments on commit 2f918bf

Please sign in to comment.