Move building Newsletter tests to their job

[MAILPOET-6178]
This commit is contained in:
Jan Lysý
2024-08-02 14:20:16 +02:00
committed by Rostislav Wolný
parent e2e1346649
commit 784d7c1189
3 changed files with 13 additions and 3 deletions

View File

@@ -265,6 +265,7 @@ const publicConfig = {
// Newsletter Editor Tests Config
const testConfig = {
name: 'test',
mode: PRODUCTION_ENV ? 'production' : 'development', // Add mode directly to testConfig
entry: {
vendor: 'webpack-vendor-index.jsx',
testNewsletterEditor: [
@@ -529,6 +530,12 @@ module.exports = (env) => {
if (env && env.BUILD_TESTS === 'build') {
configs.push(testConfig);
}
// If only the test build is requested
if (env && env.BUILD_ONLY_TESTS === 'true') {
return [testConfig];
}
return configs.map((conf) => {
const config = Object.assign({}, conf);
if (