From d5efe6c2d18cb49d2711133ab76ad0b71582b4ce Mon Sep 17 00:00:00 2001 From: toby Date: Wed, 5 Sep 2018 21:56:02 +1000 Subject: [PATCH] tests --- .../__snapshots__/mergeConfigs.test.js.snap | 21 +++++++++++++++++++ lib/core/src/server/mergeConfigs.test.js | 9 ++++++++ 2 files changed, 30 insertions(+) diff --git a/lib/core/src/server/__snapshots__/mergeConfigs.test.js.snap b/lib/core/src/server/__snapshots__/mergeConfigs.test.js.snap index b3a99e4f2f6..c33eda68bd0 100644 --- a/lib/core/src/server/__snapshots__/mergeConfigs.test.js.snap +++ b/lib/core/src/server/__snapshots__/mergeConfigs.test.js.snap @@ -12,6 +12,12 @@ Object { "r2", ], }, + "optimization": Object { + "runtimeChunk": true, + "splitChunks": Object { + "chunks": "all", + }, + }, "output": Object { "filename": "[name].js", }, @@ -48,6 +54,12 @@ Object { "r2", ], }, + "optimization": Object { + "runtimeChunk": true, + "splitChunks": Object { + "chunks": "all", + }, + }, "output": Object { "filename": "[name].js", }, @@ -84,6 +96,15 @@ Object { "r4", ], }, + "optimization": Object { + "minimizer": Array [ + "banana", + ], + "runtimeChunk": true, + "splitChunks": Object { + "chunks": "all", + }, + }, "output": Object { "filename": "[name].js", }, diff --git a/lib/core/src/server/mergeConfigs.test.js b/lib/core/src/server/mergeConfigs.test.js index 0d3d4cff8b2..da2962bcb8e 100644 --- a/lib/core/src/server/mergeConfigs.test.js +++ b/lib/core/src/server/mergeConfigs.test.js @@ -20,6 +20,12 @@ const config = { A2: 'src/B2', }, }, + optimization: { + splitChunks: { + chunks: 'all', + }, + runtimeChunk: true, + }, }; describe('mergeConfigs', () => { @@ -45,6 +51,9 @@ describe('mergeConfigs', () => { A4: 'src/B4', }, }, + optimization: { + minimizer: ['banana'], + }, }; const result = mergeConfigs(config, customConfig);