From d4686aac44643478adc4627ee7b415b656a94dd0 Mon Sep 17 00:00:00 2001 From: Peter Hedenskog Date: Fri, 27 Sep 2024 08:06:33 +0200 Subject: [PATCH] Add unique id to each configuration. The id is used in the report.json files and before this change all files have the same id inherited from the common config. By adding a unique id, we can use the report.json files directly and send metrics to our time series database. --- config/configCampaignEvents.js | 1 + config/configCodex.js | 1 + config/configDesktop.js | 1 + config/configEcho.js | 1 + config/configLogin.js | 1 + config/configMobile.js | 1 + config/configWebMaintained.js | 1 + config/configWikiLambda.js | 1 + 8 files changed, 8 insertions(+) diff --git a/config/configCampaignEvents.js b/config/configCampaignEvents.js index 5916727c..30f666ae 100644 --- a/config/configCampaignEvents.js +++ b/config/configCampaignEvents.js @@ -64,6 +64,7 @@ const scenarios = tests.map( ( test ) => { module.exports = { ...configCommon, + id: 'campaign-events', onBeforeScript: 'puppet/onBefore.js', onReadyScript: 'puppet/onReady.js', viewports: [ diff --git a/config/configCodex.js b/config/configCodex.js index 3abc2da6..0d33c486 100644 --- a/config/configCodex.js +++ b/config/configCodex.js @@ -167,6 +167,7 @@ const scenarios = components.flatMap( ( componentData ) => { module.exports = { ...configCommon, + id: 'codex', onReadyScript: 'puppet/onReady-codex.js', viewports: [ VIEWPORT_PHONE, diff --git a/config/configDesktop.js b/config/configDesktop.js index 54194a52..c76e66b2 100644 --- a/config/configDesktop.js +++ b/config/configDesktop.js @@ -272,6 +272,7 @@ const scenarios = tests.map( ( test ) => { module.exports = { ...configCommon, + id: 'desktop', onBeforeScript: 'puppet/onBefore.js', onReadyScript: 'puppet/onReady.js', viewports: [ diff --git a/config/configEcho.js b/config/configEcho.js index d6c287f1..a260a6cc 100644 --- a/config/configEcho.js +++ b/config/configEcho.js @@ -126,6 +126,7 @@ const makeMobileAndDesktopScenarios = ( tests ) => { const scenarios = makeMobileAndDesktopScenarios( baseScenarios ); module.exports = Object.assign( {}, configDesktop, { + id: 'echo', scenarios, paths: utils.makePaths( 'echo' ) } ); diff --git a/config/configLogin.js b/config/configLogin.js index f03b612b..848c7f80 100644 --- a/config/configLogin.js +++ b/config/configLogin.js @@ -40,6 +40,7 @@ const scenarios = utils.makeScenariosForSkins( [ module.exports = { ...configCommon, + id: 'login', onBeforeScript: 'puppet/onBefore.js', onReadyScript: 'puppet/onReady.js', viewports: [ diff --git a/config/configMobile.js b/config/configMobile.js index fd97f175..c3d3f3c7 100644 --- a/config/configMobile.js +++ b/config/configMobile.js @@ -129,6 +129,7 @@ const scenarios = tests.map( ( test ) => { } ); module.exports = Object.assign( {}, configDesktop, { + id: 'mobile', scenarios, paths: utils.makePaths( 'mobile' ) } ); diff --git a/config/configWebMaintained.js b/config/configWebMaintained.js index 985876de..e8a5c392 100644 --- a/config/configWebMaintained.js +++ b/config/configWebMaintained.js @@ -64,6 +64,7 @@ const nearbyScenarios = utils.makeScenariosForSkins( ); module.exports = Object.assign( {}, configDesktop, { + id: 'web-maintained', scenarios: skinScenarios.concat( quickSurveyScenarios ).concat( nearbyScenarios ), diff --git a/config/configWikiLambda.js b/config/configWikiLambda.js index 21f53bd4..47239329 100644 --- a/config/configWikiLambda.js +++ b/config/configWikiLambda.js @@ -70,6 +70,7 @@ const scenarios = tests.map( ( test ) => { module.exports = { ...configCommon, + id: 'wikilambda', onBeforeScript: 'puppet/onBefore.js', onReadyScript: 'puppet/onReady.js', viewports: [