Conversation
| node-version: '10.16.0' | ||
| - run: npm ci | ||
| - run: npm install jest --global | ||
| - run: npm run dist |
There was a problem hiding this comment.
I moved this down, after test:e2e-docker-up, because the test:e2e-docker-up might take a while. While that's completing, we can build the package in the meantime.
This should save us some time on the duration of the workflow, as well as reduce errors while calling test:e2e-docker-ping
|
|
||
| await clickReactButton( '.ellipsis-menu > .button' ); | ||
| await clickReactButton( 'div > .popover > .popover__inner > .popover__menu > .popover__menu-item:nth-child(3)' ); | ||
| await clickReactButton( '.ReactModalPortal > .ReactModal__Overlay > .ReactModal__Content > .dialog__action-buttons > .button:nth-child(2)' ); |
There was a problem hiding this comment.
I'm puzzled by the old behavior - the newLabelButton is not present to create a shipping label; and the purchase flow does not present a "purchase" button, but it requires the whole address verification and package purchase.
So I'm deleting this, we're just verifying that the refund process works.
| import { StoreOwnerFlow } from './flows'; | ||
| import { waitForSelectorAndText } from '.'; | ||
|
|
||
| const verifyAndPublish = async () => { |
| /** | ||
| * Create simple product. | ||
| */ | ||
| const createSimpleProduct = async () => { |
| /** | ||
| * Login and confirm that extension is activated on the site. | ||
| */ | ||
| const loginAndConfirmExtensionActivation = async () => { |
| @@ -1,21 +1,40 @@ | |||
| #!/bin/bash | |||
There was a problem hiding this comment.
A space should not be valid here, I don't think
| @@ -1,9 +0,0 @@ | |||
| #!/usr/bin/env bash | |||
There was a problem hiding this comment.
This file is not needed - it's residual from when we used Travis CI
| @@ -1,10 +1,8 @@ | |||
| const { useE2EJestPuppeteerConfig } = require( '@woocommerce/e2e-environment' ); | |||
|
|
|||
| const puppeteerConfig = useE2EJestPuppeteerConfig( { | |||
There was a problem hiding this comment.
just inlined this, no need to have another const
| define( 'WOOCOMMERCE_SERVICES_LOCAL_TEST_MODE', true ); | ||
| define( 'WOOCOMMERCE_CONNECT_FREQUENT_FETCH', true ); | ||
| define( 'WOOCOMMERCE_CONNECT_SERVER_URL', 'http://host.docker.internal:5000/' ); | ||
| define( 'WOOCOMMERCE_SERVICES_CI_TEST_MODE', true ); |
There was a problem hiding this comment.
Not needed when WOOCOMMERCE_SERVICES_LOCAL_TEST_MODE and JETPACK_DEV_DEBUG are already specified:
woocommerce-services/woocommerce-services.php
Lines 52 to 59 in ea71f8f
There was a problem hiding this comment.
In this PR, these are also now set in tests/bin/install.sh
|
Adding next PR reviewer on rotation |
|
👀 |
harriswong
left a comment
There was a problem hiding this comment.
E2E tests passes. LGTM 👍
Description
Fixing the e2e tests.
The main issue here was that the
@woocommerce/e2e-environmentwas outdated.It took me a while to figure it out with my local, because my local was not configured correctly.
In the end, it can be summarized with this statement:
And this PR: woocommerce/woocommerce#29346
With this fix, the e2e started (properly) failing.
It turns out, some of the selector names changed because we migrated away from Calypso. So I fixed those too.
Related issue(s)
Trying to fix #2454
Steps to reproduce & screenshots/GIFs
npm run test:e2e-dev(or just notice that they're now passing in the GH actions below 👇 )Checklist
changelog.txtentry added