test(token): added validation for vesting page without wallet connected (#673)
Co-authored-by: Rado <rado@vegaprotocol.io>
This commit is contained in:
parent
288a5d6268
commit
913703e2d8
34
apps/token-e2e/src/integration/vesting.cy.js
Normal file
34
apps/token-e2e/src/integration/vesting.cy.js
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
import navigation from '../locators/navigation.locators';
|
||||||
|
import vesting from '../locators/vesting.locators';
|
||||||
|
|
||||||
|
context('Vesting Page - verify elements on page', function () {
|
||||||
|
before('navigate to vesting page', function () {
|
||||||
|
cy.visit('/')
|
||||||
|
.get(navigation.section)
|
||||||
|
.within(() => {
|
||||||
|
cy.get(navigation.vesting).click();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
describe('with wallets disconnected', function () {
|
||||||
|
it('should have vesting tab highlighted', function () {
|
||||||
|
cy.get(navigation.section).within(() => {
|
||||||
|
cy.get(navigation.vesting).should('have.attr', 'aria-current');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should have VESTING header visible', function () {
|
||||||
|
cy.get(vesting.header).should('be.visible').and('have.text', 'Vesting');
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should have connect Eth wallet info', function () {
|
||||||
|
cy.get(vesting.connectPrompt).should('be.visible');
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should have connect Eth wallet button', function () {
|
||||||
|
cy.get(vesting.connectButton)
|
||||||
|
.should('be.visible')
|
||||||
|
.and('have.text', 'Connect Ethereum wallet');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
5
apps/token-e2e/src/locators/vesting.locators.js
Normal file
5
apps/token-e2e/src/locators/vesting.locators.js
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
export default {
|
||||||
|
header: 'header h1',
|
||||||
|
connectPrompt: '[data-testid="eth-connect-prompt"]',
|
||||||
|
connectButton: '[data-testid="connect-to-eth-btn"]',
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user