From 0eb501c576c4fe715d42df06ad8047472acb5404 Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Tue, 19 Sep 2023 18:00:54 +0200 Subject: [PATCH 1/7] fix path to copy public assets --- build/instrumentation.build.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/instrumentation.build.js b/build/instrumentation.build.js index 5abd3bd6..2442ebb1 100644 --- a/build/instrumentation.build.js +++ b/build/instrumentation.build.js @@ -68,7 +68,7 @@ export function createConfig({ }) ), copy({ - targets: [{ src: ['public/**', '!public/index.html'], dest: '${output.dir}' }] + targets: [{ src: ['public/**', '!public/index.html'], dest: `${jsOutputDirectory}` }] }), // Resolving plugins replace( From 5f09acd06379a114c48b0bc511eba3635bd229bf Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 09:08:47 +0200 Subject: [PATCH 2/7] fix path for multi theming --- build/instrumentation.build.js | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/build/instrumentation.build.js b/build/instrumentation.build.js index 2442ebb1..c2fc89ac 100644 --- a/build/instrumentation.build.js +++ b/build/instrumentation.build.js @@ -14,8 +14,6 @@ import visualizer from 'rollup-plugin-visualizer'; import vue from 'rollup-plugin-vue'; import * as fs from 'fs'; -const jsOutputDirectory = path.join(process.cwd(), 'dist'); - /** * Creates a rollup configuration for projects that use X-Components. This configuration can be customized with the options object. * @@ -49,26 +47,28 @@ export function createConfig({ }; } + const mergedOutput = { + dir: path.join(process.cwd(), 'dist'), + format: 'es', + sourcemap: true, + assetFileNames: '[name][extname]', + entryFileNames: 'app.js', + ...output + }; + return { input, - output: { - dir: jsOutputDirectory, - format: 'es', - sourcemap: true, - assetFileNames: '[name][extname]', - entryFileNames: 'app.js', - ...output - }, + output: mergedOutput, preserveEntrySignatures: false, plugins: [ ...prePlugins, del( mergeConfig('del', { - targets: [`${jsOutputDirectory}/*`] + targets: [`${mergedOutput.dir}/*`] }) ), copy({ - targets: [{ src: ['public/**', '!public/index.html'], dest: `${jsOutputDirectory}` }] + targets: [{ src: ['public/**', '!public/index.html'], dest: `${mergedOutput.dir}` }] }), // Resolving plugins replace( From b743321c7107dd16e09e250405ef637c5b19f54e Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 10:28:51 +0200 Subject: [PATCH 3/7] change queries for e2e tests --- tests/e2e/cucumber/multiple-interactions.feature | 4 ++-- tests/e2e/cucumber/predictive-components.feature | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/e2e/cucumber/multiple-interactions.feature b/tests/e2e/cucumber/multiple-interactions.feature index 5dc253aa..c0132618 100644 --- a/tests/e2e/cucumber/multiple-interactions.feature +++ b/tests/e2e/cucumber/multiple-interactions.feature @@ -25,5 +25,5 @@ Feature: Multiple interactions Examples: | query | view | nextQueryItem | filterNumber | facetName | queryWithRTs | relatedTagItem | - | dress | macbook-13 | 1 | 2 | brand | shorts | 1 | - | dress | iphone-x | 1 | 2 | brand | shorts | 1 | + | gloves | macbook-13 | 1 | 2 | brand | shorts | 1 | + | gloves | iphone-x | 1 | 2 | brand | shorts | 1 | diff --git a/tests/e2e/cucumber/predictive-components.feature b/tests/e2e/cucumber/predictive-components.feature index 2583a96d..c2bda334 100644 --- a/tests/e2e/cucumber/predictive-components.feature +++ b/tests/e2e/cucumber/predictive-components.feature @@ -16,8 +16,8 @@ Feature: Predictive components Then history queries are displayed Examples: | query | view | - | dress | macbook-13 | - | dress | iphone-x | + | gloves | macbook-13 | + | gloves | iphone-x | Scenario Outline: 2. Related tags interaction Given start page with "" size view @@ -33,8 +33,8 @@ Feature: Predictive components And related tag is displayed as not selected Examples: | query | relatedTagIndex | view | - | dress | 1 | macbook-13 | - | dress | 1 | iphone-x | + | gloves | 1 | macbook-13 | + | gloves | 1 | iphone-x | Scenario Outline: 3. Clear a history query Given start page with "" size view From bfa078eaf30716d394b7c8f49959135a06db53b1 Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 12:27:05 +0200 Subject: [PATCH 4/7] change queries for e2e tests --- tests/e2e/cucumber/multiple-interactions.feature | 4 ++-- tests/e2e/cucumber/predictive-components.feature | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/e2e/cucumber/multiple-interactions.feature b/tests/e2e/cucumber/multiple-interactions.feature index c0132618..055943fe 100644 --- a/tests/e2e/cucumber/multiple-interactions.feature +++ b/tests/e2e/cucumber/multiple-interactions.feature @@ -25,5 +25,5 @@ Feature: Multiple interactions Examples: | query | view | nextQueryItem | filterNumber | facetName | queryWithRTs | relatedTagItem | - | gloves | macbook-13 | 1 | 2 | brand | shorts | 1 | - | gloves | iphone-x | 1 | 2 | brand | shorts | 1 | + | thsirt | macbook-13 | 1 | 2 | brand | shorts | 1 | + | thsirt | iphone-x | 1 | 2 | brand | shorts | 1 | diff --git a/tests/e2e/cucumber/predictive-components.feature b/tests/e2e/cucumber/predictive-components.feature index c2bda334..a22c9af3 100644 --- a/tests/e2e/cucumber/predictive-components.feature +++ b/tests/e2e/cucumber/predictive-components.feature @@ -16,8 +16,8 @@ Feature: Predictive components Then history queries are displayed Examples: | query | view | - | gloves | macbook-13 | - | gloves | iphone-x | + | tshirt | macbook-13 | + | tshirt | iphone-x | Scenario Outline: 2. Related tags interaction Given start page with "" size view @@ -33,8 +33,8 @@ Feature: Predictive components And related tag is displayed as not selected Examples: | query | relatedTagIndex | view | - | gloves | 1 | macbook-13 | - | gloves | 1 | iphone-x | + | tshirt | 1 | macbook-13 | + | tshirt | 1 | iphone-x | Scenario Outline: 3. Clear a history query Given start page with "" size view From e0e0334fd9ccf76f100f7364070df99427d64836 Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 13:34:57 +0200 Subject: [PATCH 5/7] change queries for e2e tests --- tests/e2e/cucumber/multiple-interactions.feature | 4 ++-- tests/e2e/cucumber/predictive-components.feature | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/e2e/cucumber/multiple-interactions.feature b/tests/e2e/cucumber/multiple-interactions.feature index 055943fe..1f366030 100644 --- a/tests/e2e/cucumber/multiple-interactions.feature +++ b/tests/e2e/cucumber/multiple-interactions.feature @@ -25,5 +25,5 @@ Feature: Multiple interactions Examples: | query | view | nextQueryItem | filterNumber | facetName | queryWithRTs | relatedTagItem | - | thsirt | macbook-13 | 1 | 2 | brand | shorts | 1 | - | thsirt | iphone-x | 1 | 2 | brand | shorts | 1 | + | tshirt | macbook-13 | 1 | 2 | brand | shorts | 1 | + | tshirt | iphone-x | 1 | 2 | brand | shorts | 1 | \ No newline at end of file diff --git a/tests/e2e/cucumber/predictive-components.feature b/tests/e2e/cucumber/predictive-components.feature index a22c9af3..e2ba58cd 100644 --- a/tests/e2e/cucumber/predictive-components.feature +++ b/tests/e2e/cucumber/predictive-components.feature @@ -16,8 +16,8 @@ Feature: Predictive components Then history queries are displayed Examples: | query | view | - | tshirt | macbook-13 | - | tshirt | iphone-x | + | dress | macbook-13 | + | dress | iphone-x | Scenario Outline: 2. Related tags interaction Given start page with "" size view @@ -61,4 +61,4 @@ Feature: Predictive components Examples: | list | view | | shirt, shoe, skirt | macbook-13 | - | shirt, shoe, skirt | iphone-x | + | shirt, shoe, skirt | iphone-x | \ No newline at end of file From a74e912da409be4c5a50f1a56c5beb3e9b2a4a65 Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 15:51:29 +0200 Subject: [PATCH 6/7] fix test --- tests/e2e/cucumber/predictive-components.feature | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/e2e/cucumber/predictive-components.feature b/tests/e2e/cucumber/predictive-components.feature index e2ba58cd..adab39e0 100644 --- a/tests/e2e/cucumber/predictive-components.feature +++ b/tests/e2e/cucumber/predictive-components.feature @@ -61,4 +61,5 @@ Feature: Predictive components Examples: | list | view | | shirt, shoe, skirt | macbook-13 | - | shirt, shoe, skirt | iphone-x | \ No newline at end of file + | shirt, shoe, skirt | iphone-x | + \ No newline at end of file From d0f23b17c1a2077af3cd7b9016f9d7001eedee3a Mon Sep 17 00:00:00 2001 From: Diego Pascual Date: Wed, 20 Sep 2023 16:15:46 +0200 Subject: [PATCH 7/7] change query for e2e --- tests/e2e/cucumber/predictive-components.feature | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/e2e/cucumber/predictive-components.feature b/tests/e2e/cucumber/predictive-components.feature index adab39e0..c1cd40d3 100644 --- a/tests/e2e/cucumber/predictive-components.feature +++ b/tests/e2e/cucumber/predictive-components.feature @@ -33,8 +33,8 @@ Feature: Predictive components And related tag is displayed as not selected Examples: | query | relatedTagIndex | view | - | tshirt | 1 | macbook-13 | - | tshirt | 1 | iphone-x | + | dress | 1 | macbook-13 | + | dress | 1 | iphone-x | Scenario Outline: 3. Clear a history query Given start page with "" size view