From 89f6032cbac2cda2e442db6ff83a815b7d63e3ef Mon Sep 17 00:00:00 2001 From: Fernando Marichal Date: Tue, 29 Mar 2022 19:16:03 -0300 Subject: [PATCH] Add missing e2e tests This commit adds the tests: `testDifferentStoreCurrenciesWCPay`, `testSubscriptionsInclusion` and `testBusinessDetailsForm` --- .../activate-and-setup/complete-onboarding-wizard.ts | 5 ----- plugins/woocommerce/tests/e2e/config/default.json | 6 +++++- .../complete-onboarding-wizard.test.js | 11 +++++++---- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/packages/js/admin-e2e-tests/src/specs/activate-and-setup/complete-onboarding-wizard.ts b/packages/js/admin-e2e-tests/src/specs/activate-and-setup/complete-onboarding-wizard.ts index 1521428fe7b..f0772672b86 100644 --- a/packages/js/admin-e2e-tests/src/specs/activate-and-setup/complete-onboarding-wizard.ts +++ b/packages/js/admin-e2e-tests/src/specs/activate-and-setup/complete-onboarding-wizard.ts @@ -449,10 +449,6 @@ const testSubscriptionsInclusion = () => { await resetWooCommerceState(); } ); - afterAll( async () => { - await login.logout(); - } ); - it( 'can complete the store details section', async () => { await profileWizard.navigate(); await profileWizard.storeDetails.completeStoreDetailsSection( { @@ -533,7 +529,6 @@ const testBusinessDetailsForm = () => { const login = new Login( page ); beforeAll( async () => { - await login.login(); await resetWooCommerceState(); } ); diff --git a/plugins/woocommerce/tests/e2e/config/default.json b/plugins/woocommerce/tests/e2e/config/default.json index e70b3c6c5d8..5803d199412 100644 --- a/plugins/woocommerce/tests/e2e/config/default.json +++ b/plugins/woocommerce/tests/e2e/config/default.json @@ -195,7 +195,11 @@ "onboardingwizard": { "industry": "Test industry", "numberofproducts": "1 - 10", - "sellingelsewhere": "No" + "sellingelsewhere": "No", + "sellingOnAnotherPlatform": "Yes, on another platform", + "number_employees": "< 10", + "revenue": "Up to $2,500.00", + "other_platform_name": "Etsy" }, "settings": { "shipping": { diff --git a/plugins/woocommerce/tests/e2e/specs/activate-and-setup/complete-onboarding-wizard.test.js b/plugins/woocommerce/tests/e2e/specs/activate-and-setup/complete-onboarding-wizard.test.js index b9920ab7cbc..77af197d123 100644 --- a/plugins/woocommerce/tests/e2e/specs/activate-and-setup/complete-onboarding-wizard.test.js +++ b/plugins/woocommerce/tests/e2e/specs/activate-and-setup/complete-onboarding-wizard.test.js @@ -1,11 +1,11 @@ const { testAdminOnboardingWizard, testSelectiveBundleWCPay, + testDifferentStoreCurrenciesWCPay, + testSubscriptionsInclusion, + testBusinessDetailsForm, } = require( '@woocommerce/admin-e2e-tests' ); -const { - withRestApi, - IS_RETEST_MODE, -} = require( '@woocommerce/e2e-utils' ); +const { withRestApi, IS_RETEST_MODE } = require( '@woocommerce/e2e-utils' ); // Reset onboarding profile when re-running tests on a site if ( IS_RETEST_MODE ) { @@ -14,3 +14,6 @@ if ( IS_RETEST_MODE ) { testAdminOnboardingWizard(); testSelectiveBundleWCPay(); +testDifferentStoreCurrenciesWCPay(); +testSubscriptionsInclusion(); +testBusinessDetailsForm();