Skip to content

Commit

Permalink
Update Docker Image, .node-version to use Node 12.18.0, fix additiona…
Browse files Browse the repository at this point in the history
…l flake (#428)

* update docker image

* update node version to 12.18

* wait for comment to be posted

* set firefoxGcInterval to null per cypress-io/cypress#6813

* remove quotes from cypress config

* add assertion to fix additional flake

* set firefoxGcInterval to null in cypress.json vs circle config

* ensure like button click is registered on server
  • Loading branch information
Kevin Old committed Jun 16, 2020
1 parent 9a0e152 commit b074f0c
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Expand Up @@ -7,7 +7,7 @@ orbs:
executors:
with-chrome-and-firefox:
docker:
- image: "cypress/browsers:node12.16.2-chrome81-ff75"
- image: "cypress/browsers:node12.18.0-chrome83-ff77"

# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Commands ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #
commands:
Expand Down Expand Up @@ -118,7 +118,7 @@ linux-workflow: &linux-workflow
name: "UI Tests - Firefox - Mobile"
browser: firefox
spec: cypress/tests/ui/*
config: "viewportWidth=375,viewportHeight=667"
config: viewportWidth=375,viewportHeight=667
executor: with-chrome-and-firefox
wait-on: "http://localhost:3000"
yarn: true
Expand Down
2 changes: 1 addition & 1 deletion .node-version
@@ -1 +1 @@
12.16
12.18
1 change: 1 addition & 0 deletions cypress.json
Expand Up @@ -4,6 +4,7 @@
"integrationFolder": "cypress/tests",
"viewportHeight": 1000,
"viewportWidth": 1280,
"firefoxGcInterval": null,
"env": {
"apiUrl": "http://localhost:3001",
"mobileViewportWidthBreakpoint": 414,
Expand Down
7 changes: 7 additions & 0 deletions cypress/tests/ui/notifications.spec.ts
Expand Up @@ -86,7 +86,11 @@ describe("Notifications", function () {
cy.visit(`/transaction/${transaction.id}`);
});

const likesCountSelector = "[data-test*=transaction-like-count]";
cy.contains(likesCountSelector, 0);
cy.getBySelLike("like-button").click();
cy.getBySelLike("like-button").should("be.disabled");
cy.contains(likesCountSelector, 1);

cy.switchUser(ctx.userA.username);

Expand All @@ -97,6 +101,7 @@ describe("Notifications", function () {
cy.location("pathname").should("equal", "/notifications");

cy.getBySelLike("notification-list-item")
.should("have.length", 9)
.first()
.should("contain", ctx.userC.firstName)
.and("contain", "liked");
Expand Down Expand Up @@ -125,6 +130,8 @@ describe("Notifications", function () {

cy.getBySelLike("comment-input").type("Thank You{enter}");

cy.wait("@postComment");

cy.switchUser(ctx.userB.username);

cy.getBySelLike("notifications-link").click();
Expand Down

0 comments on commit b074f0c

Please sign in to comment.