|
|
@@ -7,12 +7,18 @@ import {
|
|
|
facetValueCollectionFilter,
|
|
|
mergeConfig,
|
|
|
} from '@vendure/core';
|
|
|
-import { createTestEnvironment, E2E_DEFAULT_CHANNEL_TOKEN, SimpleGraphQLClient } from '@vendure/testing';
|
|
|
+import {
|
|
|
+ createTestEnvironment,
|
|
|
+ E2E_DEFAULT_CHANNEL_TOKEN,
|
|
|
+ registerInitializer,
|
|
|
+ SimpleGraphQLClient,
|
|
|
+ SqljsInitializer,
|
|
|
+} from '@vendure/testing';
|
|
|
import gql from 'graphql-tag';
|
|
|
import path from 'path';
|
|
|
|
|
|
import { initialData } from '../../../e2e-common/e2e-initial-data';
|
|
|
-import { testConfig, TEST_SETUP_TIMEOUT_MS } from '../../../e2e-common/test-config';
|
|
|
+import { TEST_SETUP_TIMEOUT_MS, testConfig } from '../../../e2e-common/test-config';
|
|
|
|
|
|
import {
|
|
|
AssignProductsToChannel,
|
|
|
@@ -46,8 +52,8 @@ import {
|
|
|
} from './graphql/generated-e2e-admin-types';
|
|
|
import { LogicalOperator, SearchProductsShop } from './graphql/generated-e2e-shop-types';
|
|
|
import {
|
|
|
- ASSIGN_PRODUCTVARIANT_TO_CHANNEL,
|
|
|
ASSIGN_PRODUCT_TO_CHANNEL,
|
|
|
+ ASSIGN_PRODUCTVARIANT_TO_CHANNEL,
|
|
|
CREATE_CHANNEL,
|
|
|
CREATE_COLLECTION,
|
|
|
CREATE_FACET,
|
|
|
@@ -56,8 +62,8 @@ import {
|
|
|
DELETE_ASSET,
|
|
|
DELETE_PRODUCT,
|
|
|
DELETE_PRODUCT_VARIANT,
|
|
|
- REMOVE_PRODUCTVARIANT_FROM_CHANNEL,
|
|
|
REMOVE_PRODUCT_FROM_CHANNEL,
|
|
|
+ REMOVE_PRODUCTVARIANT_FROM_CHANNEL,
|
|
|
UPDATE_ASSET,
|
|
|
UPDATE_COLLECTION,
|
|
|
UPDATE_PRODUCT,
|
|
|
@@ -67,6 +73,8 @@ import {
|
|
|
import { SEARCH_PRODUCTS_SHOP } from './graphql/shop-definitions';
|
|
|
import { awaitRunningJobs } from './utils/await-running-jobs';
|
|
|
|
|
|
+registerInitializer('sqljs', new SqljsInitializer(path.join(__dirname, '__data__'), 1000));
|
|
|
+
|
|
|
// Some of these tests have many steps and can timeout
|
|
|
// on the default of 5s.
|
|
|
jest.setTimeout(10000);
|