simorgh icon indicating copy to clipboard operation
simorgh copied to clipboard

test(WSTEAMA-1180): update topicPage tests to not use BFF

Open karinathomasbbc opened this issue 1 year ago • 0 comments

Resolves JIRA [WSTEAMA-1180]

Overall changes

Refactor and stabilise tests for topic page.

Code changes

  1. Removed cy.getPageData function and replaced it with getPageDataFromWindow
  2. Used window.SIMORGH_DATA.pageData for canonical tests
  3. Unskipped test
  4. Added a BeforeEach() function, to ensure we always start from the path being tested and make the tests deterministic

Testing

  • [x] Cypress Tests on PR passing
Environment Smoke Command Status
local true CYPRESS_APP_ENV=local CYPRESS_SMOKE=true yarn test:e2e  N/A
local false CYPRESS_APP_ENV=local yarn test:e2e  N/A
test true CYPRESS_APP_ENV=test CYPRESS_SMOKE=true yarn cypress  Pass
test false CYPRESS_APP_ENV=test yarn cypress  Pass
live true CYPRESS_APP_ENV=live CYPRESS_SMOKE=true yarn cypress  Pass
live false CYPRESS_APP_ENV=live yarn cypress  Pass

Helpful Links

Add Links to useful resources related to this PR if applicable.

Coding Standards

Repository use guidelines

karinathomasbbc avatar May 13 '24 10:05 karinathomasbbc