Test/1689 staking acs (#1698)
* test: vesting test with eth wallet connected * chore: acs for staking added * chore: acs for staking income
This commit is contained in:
parent
6ec6c6b8b7
commit
7824c39bfe
@ -11,6 +11,7 @@ const stakeAddStakeRadioButton = '[data-testid="add-stake-radio"]';
|
|||||||
const stakeMaximumTokens = '[data-testid="token-amount-use-maximum"]';
|
const stakeMaximumTokens = '[data-testid="token-amount-use-maximum"]';
|
||||||
const totalStake = '[data-testid="total-stake"]';
|
const totalStake = '[data-testid="total-stake"]';
|
||||||
const stakeShare = '[data-testid="stake-percentage"]';
|
const stakeShare = '[data-testid="stake-percentage"]';
|
||||||
|
const nominatedStake = '[data-testid="nominated-stake"]';
|
||||||
const vegaWalletPublicKeyShort = Cypress.env('vegaWalletPublicKeyShort');
|
const vegaWalletPublicKeyShort = Cypress.env('vegaWalletPublicKeyShort');
|
||||||
const vegaWalletAssociatedBalance = '[data-testid="currency-value"]';
|
const vegaWalletAssociatedBalance = '[data-testid="currency-value"]';
|
||||||
const vegaWalletUnstakedBalance =
|
const vegaWalletUnstakedBalance =
|
||||||
@ -88,13 +89,12 @@ context(
|
|||||||
1.0,
|
1.0,
|
||||||
txTimeout
|
txTimeout
|
||||||
);
|
);
|
||||||
|
|
||||||
// 2001-STKE-039
|
// 2001-STKE-039
|
||||||
cy.get(vegaWalletStakedBalances, txTimeout)
|
cy.get(vegaWalletStakedBalances, txTimeout)
|
||||||
.should('contain', 2.0, txTimeout)
|
.should('contain', 2.0, txTimeout)
|
||||||
.and('contain', partValidatorId);
|
.and('contain', partValidatorId);
|
||||||
|
|
||||||
cy.get(stakeNextEpochValue, epochTimeout) // 2001-STKE-016
|
cy.get(stakeNextEpochValue, epochTimeout) // 2001-STKE-016 2001-STKE-038
|
||||||
.contains(2.0, epochTimeout)
|
.contains(2.0, epochTimeout)
|
||||||
.should('be.visible');
|
.should('be.visible');
|
||||||
|
|
||||||
@ -102,6 +102,8 @@ context(
|
|||||||
.contains(2.0, epochTimeout)
|
.contains(2.0, epochTimeout)
|
||||||
.should('be.visible');
|
.should('be.visible');
|
||||||
|
|
||||||
|
cy.get(nominatedStake).should('have.text', 2); // 2001-STKE-017 2002-SINC-007
|
||||||
|
|
||||||
cy.navigate_to('staking');
|
cy.navigate_to('staking');
|
||||||
|
|
||||||
cy.validate_validator_list_total_stake_and_share(
|
cy.validate_validator_list_total_stake_and_share(
|
||||||
@ -376,6 +378,7 @@ context(
|
|||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// 2001-STKE-045
|
||||||
it('Able to remove a full stake against a validator', function () {
|
it('Able to remove a full stake against a validator', function () {
|
||||||
cy.staking_page_associate_tokens('3');
|
cy.staking_page_associate_tokens('3');
|
||||||
|
|
||||||
|
@ -138,7 +138,7 @@ context('Staking Page - verify elements on page', function () {
|
|||||||
cy.click_on_validator_from_list(0);
|
cy.click_on_validator_from_list(0);
|
||||||
});
|
});
|
||||||
|
|
||||||
// 2001-STKE-005
|
// 2001-STKE-006
|
||||||
it('Should be able to see validator name', function () {
|
it('Should be able to see validator name', function () {
|
||||||
cy.get(validatorTitle).should('not.be.empty');
|
cy.get(validatorTitle).should('not.be.empty');
|
||||||
});
|
});
|
||||||
@ -204,7 +204,7 @@ context('Staking Page - verify elements on page', function () {
|
|||||||
cy.get(nominatedStake).invoke('text').should('match', stakeNumberRegex);
|
cy.get(nominatedStake).invoke('text').should('match', stakeNumberRegex);
|
||||||
});
|
});
|
||||||
|
|
||||||
// 2001-STKE-011
|
// 2001-STKE-011 2002-SINC-001 2002-SINC-002
|
||||||
it('should be able to see epoch information', function () {
|
it('should be able to see epoch information', function () {
|
||||||
const epochTitle = 'h3';
|
const epochTitle = 'h3';
|
||||||
const nextEpochInfo = 'p';
|
const nextEpochInfo = 'p';
|
||||||
|
@ -28,5 +28,21 @@ context(
|
|||||||
.and('have.text', 'Connect Ethereum wallet');
|
.and('have.text', 'Connect Ethereum wallet');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
describe('with eth wallet connected', function () {
|
||||||
|
before('connect eth wallet', function () {
|
||||||
|
cy.ethereum_wallet_connect();
|
||||||
|
});
|
||||||
|
|
||||||
|
// 1005-VEST-001
|
||||||
|
// 1005-VEST-002
|
||||||
|
it('Able to view tranches', function () {
|
||||||
|
cy.get('[href="/tranches"]')
|
||||||
|
.should('have.text', 'all tranches')
|
||||||
|
.click();
|
||||||
|
cy.url().should('include', '/tranches');
|
||||||
|
cy.get('h1').should('contain.text', 'Vesting tranches');
|
||||||
|
});
|
||||||
|
});
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
@ -302,6 +302,7 @@ context(
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// 2002-SINC-016
|
||||||
describe('when assets exist in vegawallet', function () {
|
describe('when assets exist in vegawallet', function () {
|
||||||
before('send-faucet assets to connected vega wallet', function () {
|
before('send-faucet assets to connected vega wallet', function () {
|
||||||
cy.vega_wallet_receive_fauceted_asset(
|
cy.vega_wallet_receive_fauceted_asset(
|
||||||
|
Loading…
Reference in New Issue
Block a user