Skip to content

Commit

Permalink
DAH 1936 fix e2e tests (#2042)
Browse files Browse the repository at this point in the history
* DAH-1936 fix endpoint being intercepted in machineTranslations e2e test

* DAH-1936 use regex to capture either call

* DAH-1936 extend timeout

* DAH-1936 extend timeout

* DAH-1936 increase timeout

* DAH-1936 bump up default timeouts for cypress tests

* DAH-1936 remove unneeded changes
  • Loading branch information
tallulahkay authored Dec 21, 2023
1 parent 52617c7 commit 4e897c1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import 'dotenv/config'
import { defineConfig } from 'cypress'

export default defineConfig({
defaultCommandTimeout: 10000,
defaultCommandTimeout: 120000, // 2 mins
projectId: 'dahlia-housing-portal',
pageLoadTimeout: 10000,
pageLoadTimeout: 120000, // 2 mins
reporterOptions: {
mochaFile: 'cypress/results/tests-[hash].xml',
toConsole: true,
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/listingDetails/machineTranslations.e2e.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const verifyMachineTranslations = (language, id, translation) => {
cy.intercept("POST", "https://translate-pa.googleapis.com/v1/translateHtml").as("getTranslate")
cy.intercept("POST", /^https:\/\/translate/).as("getTranslate")
cy.visit(`${language}/listings/${id}?react=true`)
cy.wait("@getTranslate")
return cy.contains(translation)
Expand Down

0 comments on commit 4e897c1

Please sign in to comment.