Skip to content
This repository has been archived by the owner on Nov 10, 2023. It is now read-only.

Commit

Permalink
Chore: fix the balances test (#3981)
Browse files Browse the repository at this point in the history
  • Loading branch information
katspaugh authored Jun 17, 2022
1 parent 5cc06e9 commit 35c9c76
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions cypress/integration/smoke/balances.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@ const balanceRowTestId = '[data-testid=balance-row]'

const TEST_SAFE = 'rin:0x11Df0fa87b30080d59eba632570f620e37f2a8f7'
const ASSETS_LENGTH = 7
const DAI_ROW_NUMBER = 0
const TOKEN_AMOUNT_COLUMN = 1
const FIAT_AMOUNT_COLUMN = 2
const WETH_ROW_NUMBER = 1
const USDC_ROW_NUMBER = 3

describe('Assets > Coins', () => {
const TOKEN_AMOUNT_COLUMN = 1
const FIAT_AMOUNT_COLUMN = 2

describe('Assets > Coins', () => {
// Fiat balance regex
const fiatRegex = new RegExp(`([0-9]{1,3},)*[0-9]{1,3}.[0-9]{2}`)
// Token balance regex
Expand All @@ -24,8 +27,6 @@ describe('Assets > Coins', () => {
})

it('should have Dai', () => {
const DAI_ROW_NUMBER = 0

// First row should be Dai
cy.get(balanceRowTestId).eq(DAI_ROW_NUMBER).contains('Dai')

Expand All @@ -40,8 +41,6 @@ describe('Assets > Coins', () => {
})

it('should have Wrapped Ether', () => {
const WETH_ROW_NUMBER = 1

// Second row should be Wrapped Ether
cy.get(balanceRowTestId).eq(WETH_ROW_NUMBER).contains('Wrapped Ether')

Expand All @@ -59,8 +58,6 @@ describe('Assets > Coins', () => {
})

it('should have USD Coin', () => {
const USDC_ROW_NUMBER = 2

// Third row should be USD Coin
cy.get(balanceRowTestId).eq(USDC_ROW_NUMBER).contains('USD Coin')

Expand Down

0 comments on commit 35c9c76

Please sign in to comment.