Merge pull request #31644 from woocommerce/e2e/import-cleanup
e2e-core-test package cleanup
This commit is contained in:
commit
c9696e66b9
|
@ -9,6 +9,36 @@
|
|||
"action": "add",
|
||||
"cwd": "packages/js/e2e-core-tests"
|
||||
}
|
||||
},
|
||||
"build": {
|
||||
"executor": "@nrwl/workspace:run-script",
|
||||
"options": {
|
||||
"script": "build"
|
||||
}
|
||||
},
|
||||
"clean": {
|
||||
"executor": "@nrwl/workspace:run-script",
|
||||
"options": {
|
||||
"script": "clean"
|
||||
}
|
||||
},
|
||||
"compile": {
|
||||
"executor": "@nrwl/workspace:run-script",
|
||||
"options": {
|
||||
"script": "compile"
|
||||
}
|
||||
},
|
||||
"prepare": {
|
||||
"executor": "@nrwl/workspace:run-script",
|
||||
"options": {
|
||||
"script": "prepare"
|
||||
}
|
||||
},
|
||||
"lint": {
|
||||
"executor": "@nrwl/workspace:run-script",
|
||||
"options": {
|
||||
"script": "lint"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -7,7 +7,6 @@ const {
|
|||
verifyCheckboxIsSet,
|
||||
verifyValueOfInputField,
|
||||
uiUnblocked,
|
||||
evalAndClick,
|
||||
createOrder,
|
||||
clickAndWaitForSelector,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
const config = require( 'config' );
|
||||
|
||||
const {
|
||||
merchant,
|
||||
withRestApi,
|
||||
|
|
|
@ -7,9 +7,14 @@ const {
|
|||
merchant,
|
||||
uiUnblocked,
|
||||
verifyAndPublish,
|
||||
createSimpleProduct
|
||||
createSimpleProduct,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
let productId;
|
||||
|
||||
const runProductEditDetailsTest = () => {
|
||||
|
|
|
@ -11,7 +11,7 @@ const {
|
|||
setBrowserViewport,
|
||||
verifyAndPublish,
|
||||
waitForSelector,
|
||||
waitForSelectorWithoutThrow
|
||||
waitForSelectorWithoutThrow,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
const {
|
||||
waitAndClick,
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
const {
|
||||
merchant,
|
||||
settingsPageSaveChanges,
|
||||
verifyValueOfInputField
|
||||
verifyValueOfInputField,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
|
|
|
@ -8,7 +8,7 @@ const {
|
|||
settingsPageSaveChanges,
|
||||
unsetCheckbox,
|
||||
verifyCheckboxIsSet,
|
||||
verifyCheckboxIsUnset
|
||||
verifyCheckboxIsUnset,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
const runProductSettingsTest = () => {
|
||||
|
|
|
@ -2,6 +2,10 @@
|
|||
* Internal dependencies
|
||||
*/
|
||||
const { merchant, withRestApi } = require('@woocommerce/e2e-utils');
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { lorem, helpers } = require('faker');
|
||||
|
||||
const runAddShippingClassesTest = () => {
|
||||
|
|
|
@ -12,11 +12,7 @@ const {
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require( 'config' );
|
||||
const firstProductPrice = config.has( 'products.simple.price' ) ? config.get( 'products.simple.price' ) : '9.99';
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
*/
|
||||
const {
|
||||
shopper,
|
||||
createCoupon,
|
||||
createSimpleProduct,
|
||||
uiUnblocked,
|
||||
applyCoupon,
|
||||
|
@ -14,11 +13,7 @@ const { getCouponId, getCouponsTable } = require( '../utils/coupons' );
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const runCartApplyCouponsTest = () => {
|
||||
describe('Cart applying coupons', () => {
|
||||
|
|
|
@ -5,17 +5,13 @@ const {
|
|||
shopper,
|
||||
withRestApi,
|
||||
createSimpleProduct,
|
||||
uiUnblocked
|
||||
uiUnblocked,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require( 'config' );
|
||||
const simpleProductName = config.get( 'products.simple.name' );
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
*/
|
||||
const {
|
||||
shopper,
|
||||
createCoupon,
|
||||
createSimpleProduct,
|
||||
uiUnblocked,
|
||||
applyCoupon,
|
||||
|
@ -15,11 +14,7 @@ const { getCouponId, getCouponsTable } = require( '../utils/coupons' );
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
|
||||
const runCheckoutApplyCouponsTest = () => {
|
||||
|
|
|
@ -15,11 +15,7 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require( 'config' );
|
||||
const customerBilling = config.get( 'addresses.customer.billing' );
|
||||
|
|
|
@ -13,11 +13,7 @@
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require('config');
|
||||
|
||||
|
|
|
@ -9,6 +9,11 @@ const {
|
|||
uiUnblocked,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll, afterAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require( 'config' );
|
||||
const simpleProductName = config.get( 'products.simple.name' );
|
||||
const singleProductPrice = config.has('products.simple.price') ? config.get('products.simple.price') : '9.99';
|
||||
|
|
|
@ -9,6 +9,11 @@ const {
|
|||
withRestApi,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll, afterAll } = require( '@jest/globals' );
|
||||
|
||||
const customerEmailAddress = 'john.doe.test@example.com';
|
||||
|
||||
const runMyAccountCreateAccountTest = () => {
|
||||
|
|
|
@ -9,6 +9,11 @@ const {
|
|||
uiUnblocked
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll, afterAll } = require( '@jest/globals' );
|
||||
|
||||
let simplePostIdValue;
|
||||
let orderNum;
|
||||
const config = require( 'config' );
|
||||
|
|
|
@ -6,6 +6,11 @@ const {
|
|||
shopper,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe } = require( '@jest/globals' );
|
||||
|
||||
const pages = [
|
||||
['Orders', 'my-account/orders', shopper.goToOrders],
|
||||
['Downloads', 'my-account/downloads', shopper.goToDownloads],
|
||||
|
|
|
@ -10,6 +10,11 @@
|
|||
deleteAllEmailLogs,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll, afterAll } = require( '@jest/globals' );
|
||||
|
||||
let simplePostIdValue;
|
||||
let orderId;
|
||||
const config = require( 'config' );
|
||||
|
@ -17,15 +22,6 @@ const simpleProductName = config.get( 'products.simple.name' );
|
|||
const customerEmail = config.get( 'addresses.customer.billing.email' );
|
||||
const storeName = 'WooCommerce Core E2E Test Suite';
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
|
||||
const runOrderEmailReceivingTest = () => {
|
||||
describe('Shopper Order Email Receiving', () => {
|
||||
beforeAll(async () => {
|
||||
|
|
|
@ -11,11 +11,7 @@ const {
|
|||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const {
|
||||
it,
|
||||
describe,
|
||||
beforeAll,
|
||||
} = require( '@jest/globals' );
|
||||
const { it, beforeAll } = require( '@jest/globals' );
|
||||
|
||||
const config = require( 'config' );
|
||||
const simpleProductName = config.get( 'products.simple.name' );
|
||||
|
|
|
@ -6,9 +6,13 @@ const {
|
|||
createSimpleProduct,
|
||||
createVariableProduct,
|
||||
createGroupedProduct,
|
||||
uiUnblocked
|
||||
uiUnblocked,
|
||||
} = require( '@woocommerce/e2e-utils' );
|
||||
|
||||
/**
|
||||
* External dependencies
|
||||
*/
|
||||
const { it, describe, beforeAll } = require( '@jest/globals' );
|
||||
const config = require( 'config' );
|
||||
|
||||
// Variables for simple product
|
||||
|
|
|
@ -2,9 +2,7 @@ import { GroupedProduct } from '@woocommerce/api';
|
|||
import { Factory } from 'fishery';
|
||||
|
||||
/**
|
||||
* Creates a new factory for creating variable products.
|
||||
* This does not include creating product variations.
|
||||
* Instead, use `variationFactory()` for that.
|
||||
* Creates a new factory for creating grouped products.
|
||||
*
|
||||
* @param {HTTPClient} httpClient The HTTP client we will give the repository.
|
||||
* @return {AsyncFactory} The factory for creating models.
|
||||
|
|
Loading…
Reference in New Issue