diff --git a/apps/trading-e2e/src/integration/market-liquidity.cy.ts b/apps/trading-e2e/src/integration/market-liquidity.cy.ts index d625d12ed..b61997648 100644 --- a/apps/trading-e2e/src/integration/market-liquidity.cy.ts +++ b/apps/trading-e2e/src/integration/market-liquidity.cy.ts @@ -102,7 +102,6 @@ describe('liquidity table - trading', { tags: '@smoke' }, () => { cy.get(rowSelector).first().find(colCreatedAt).should('not.be.empty'); cy.get(rowSelector).first().find(colUpdatedAt).should('not.be.empty'); }); - // #4079 it.skip('liquidity status column should be sorted properly', () => { // 5002-LIQP-003 const liquidityColDefault = ['Active', 'Pending']; diff --git a/apps/trading-e2e/src/integration/market-selector.cy.ts b/apps/trading-e2e/src/integration/market-selector.cy.ts index 42792e2b3..2141aa02d 100644 --- a/apps/trading-e2e/src/integration/market-selector.cy.ts +++ b/apps/trading-e2e/src/integration/market-selector.cy.ts @@ -68,6 +68,7 @@ describe('markets selector', { tags: '@smoke' }, () => { .each((item, i) => { const market = data[i]; // 6001-MARK-021 + // 6001-MARK-022 expect(item.find('h3').text()).equals(market.code); expect( item.find('[data-testid="market-selector-data-row"]').eq(0).text() @@ -85,8 +86,19 @@ describe('markets selector', { tags: '@smoke' }, () => { }); }); - // 6001-MARK-027 + it('can see all markets link', () => { + // 6001-MARK-026 + cy.getByTestId('market-selector').within(() => { + cy.getByTestId('all-markets-link') + .should('be.visible') + .and('have.text', 'All markets') + .and('have.attr', 'href') + .and('contain', '#/markets/all'); + }); + }); + it('can use the filter options', () => { + // 6001-MARK-027 // product type cy.getByTestId('product-Spot').click(); cy.getByTestId(list).contains('Spot markets coming soon.'); @@ -104,4 +116,29 @@ describe('markets selector', { tags: '@smoke' }, () => { cy.getByTestId(searchInput).clear(); cy.getByTestId(list).find('a').should('have.length', 4); }); + + it('can sort by by top gaining and top losing market', () => { + // 6001-MARK-030 + // 6001-MARK-031 + // 6001-MARK-032 + // 6001-MARK-033 + cy.getByTestId(' sort-trigger').click(); + cy.getByTestId('sort-item-Gained') + .contains('Top gaining') + .should('be.visible'); + cy.getByTestId('sort-item-Lost') + .contains('Top losing') + .should('be.visible'); + cy.getByTestId('sort-item-New') + .contains('New markets') + .should('be.visible'); + }); + + it('can filter by settlement asset', () => { + // 6001-MARK-028 + cy.getByTestId('asset-trigger').click(); + cy.getByTestId('asset-id-asset-3').contains('tBTC').click(); + cy.getByTestId(list).find('a').should('have.length', 1); + cy.getByTestId(list).find('a').eq(0).contains('ETHBTC.QM21'); + }); }); diff --git a/apps/trading-e2e/src/integration/trading-accounts.cy.ts b/apps/trading-e2e/src/integration/trading-accounts.cy.ts index 3502929e8..5ca544260 100644 --- a/apps/trading-e2e/src/integration/trading-accounts.cy.ts +++ b/apps/trading-e2e/src/integration/trading-accounts.cy.ts @@ -129,6 +129,7 @@ describe('accounts', { tags: '@smoke' }, () => { }); } }); + // 7001-COLL-010 it('sorting by asset', () => { cy.getByTestId('Collateral').click(); const marketsSortedDefault = ['tBTC', 'tEURO', 'tDAI', 'tBTC']; diff --git a/apps/trading/client-pages/market/market-selector.tsx b/apps/trading/client-pages/market/market-selector.tsx index 812d1c5f2..b5ef9d810 100644 --- a/apps/trading/client-pages/market/market-selector.tsx +++ b/apps/trading/client-pages/market/market-selector.tsx @@ -151,7 +151,11 @@ export const MarketSelector = ({
- + {t('All markets')}