c3f65e3abd
* wip * add some v2 paths * start to refactor migrate page update deploy addresses * fix tests * stub out v3 remove * silence some lint warnings
40 lines
1.8 KiB
TypeScript
40 lines
1.8 KiB
TypeScript
describe('Remove Liquidity', () => {
|
|
it('redirects', () => {
|
|
cy.visit('/remove/v2/0xc778417E063141139Fce010982780140Aa0cD5Ab-0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85')
|
|
cy.url().should(
|
|
'contain',
|
|
'/remove/v2/0xc778417E063141139Fce010982780140Aa0cD5Ab/0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85'
|
|
)
|
|
})
|
|
|
|
it('eth remove', () => {
|
|
cy.visit('/remove/v2/ETH/0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85')
|
|
cy.get('#remove-liquidity-tokena-symbol').should('contain.text', 'ETH')
|
|
cy.get('#remove-liquidity-tokenb-symbol').should('contain.text', 'MKR')
|
|
})
|
|
|
|
it('eth remove swap order', () => {
|
|
cy.visit('/remove/v2/0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85/ETH')
|
|
cy.get('#remove-liquidity-tokena-symbol').should('contain.text', 'MKR')
|
|
cy.get('#remove-liquidity-tokenb-symbol').should('contain.text', 'ETH')
|
|
})
|
|
|
|
it('loads the two correct tokens', () => {
|
|
cy.visit('/remove/v2/0xc778417E063141139Fce010982780140Aa0cD5Ab-0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85')
|
|
cy.get('#remove-liquidity-tokena-symbol').should('contain.text', 'WETH')
|
|
cy.get('#remove-liquidity-tokenb-symbol').should('contain.text', 'MKR')
|
|
})
|
|
|
|
it('does not crash if ETH is duplicated', () => {
|
|
cy.visit('/remove/v2/0xc778417E063141139Fce010982780140Aa0cD5Ab-0xc778417E063141139Fce010982780140Aa0cD5Ab')
|
|
cy.get('#remove-liquidity-tokena-symbol').should('contain.text', 'WETH')
|
|
cy.get('#remove-liquidity-tokenb-symbol').should('contain.text', 'WETH')
|
|
})
|
|
|
|
it('token not in storage is loaded', () => {
|
|
cy.visit('/remove/v2/0xb290b2f9f8f108d03ff2af3ac5c8de6de31cdf6d-0xF9bA5210F91D0474bd1e1DcDAeC4C58E359AaD85')
|
|
cy.get('#remove-liquidity-tokena-symbol').should('contain.text', 'SKL')
|
|
cy.get('#remove-liquidity-tokenb-symbol').should('contain.text', 'MKR')
|
|
})
|
|
})
|