mirror of
https://github.com/luxfi/safe-wallet.git
synced 2026-10-30 15:19:21 +00:00
* chore: reduce repetitive tests; remove tests for unreachable pages * chore: merge all tests for Settings tabs into one file to avoid setup repetition * feat: add a test for the collapsed sidebar * feat: fix earn, stake, bridge, swap tests * fix: Welcome page tests * fix: NFTs and Positions tests * fix: spaces tests setup with a real space instead of mocks * feat: spaces dashboard tests * feat: new visual tests for Spaces Settings, Secutiry Hub and Activity Log * chore: removed unused mock files * feat: add tests for Spaces AB, Members and Safe Accounts in Spaces * chore: update `COVERAGE.md` for visual regression tests
28 lines
929 B
JavaScript
28 lines
929 B
JavaScript
import * as constants from '../../support/constants.js'
|
|
import * as main from '../pages/main.page.js'
|
|
import * as nfts from '../pages/nfts.pages.js'
|
|
import { getSafes, CATEGORIES } from '../../support/safes/safesHandler.js'
|
|
import { mockVisualTestApis } from '../../support/visual-mocks.js'
|
|
|
|
let nftSafes = []
|
|
|
|
describe('[VISUAL] NFTs page screenshots', { defaultCommandTimeout: 60000, ...constants.VISUAL_VIEWPORT }, () => {
|
|
before(async () => {
|
|
nftSafes = await getSafes(CATEGORIES.nfts)
|
|
})
|
|
|
|
beforeEach(() => {
|
|
mockVisualTestApis()
|
|
})
|
|
|
|
it('[VISUAL] Screenshot NFTs page with items', () => {
|
|
cy.fixture('nfts/nfts.json').then((mockData) => {
|
|
cy.intercept('GET', constants.collectiblesEndpoint, mockData).as('getCollectibles')
|
|
cy.visit(constants.balanceNftsUrl + nftSafes.SEP_NFT_SAFE_1)
|
|
})
|
|
cy.wait('@getCollectibles')
|
|
nfts.waitForNftItems(1)
|
|
main.awaitVisualStability()
|
|
})
|
|
})
|