2021-04-14 16:41:15 +02:00
|
|
|
/* eslint-disable @typescript-eslint/naming-convention */
|
2020-06-25 09:41:58 +02:00
|
|
|
const glob = require("glob");
|
|
|
|
const path = require("path");
|
|
|
|
const webpack = require("webpack");
|
|
|
|
|
|
|
|
const target = "web";
|
|
|
|
const distdir = path.join(__dirname, "dist", "web");
|
|
|
|
|
|
|
|
module.exports = [
|
|
|
|
{
|
|
|
|
// bundle used for Karma tests
|
|
|
|
target: target,
|
|
|
|
entry: glob.sync("./build/**/*.spec.js"),
|
|
|
|
output: {
|
|
|
|
path: distdir,
|
|
|
|
filename: "tests.js",
|
|
|
|
},
|
2021-05-25 16:53:44 +02:00
|
|
|
plugins: [
|
2021-10-22 00:08:06 +02:00
|
|
|
new webpack.EnvironmentPlugin({
|
|
|
|
SIMAPP44_ENABLED: "",
|
|
|
|
SLOW_SIMAPP44_ENABLED: "",
|
2022-07-06 11:28:51 +02:00
|
|
|
SIMAPP46_ENABLED: "",
|
|
|
|
SLOW_SIMAPP46_ENABLED: "",
|
2023-04-06 16:52:52 +02:00
|
|
|
SIMAPP47_ENABLED: "",
|
|
|
|
SLOW_SIMAPP47_ENABLED: "",
|
2023-11-22 10:38:54 +01:00
|
|
|
SIMAPP50_ENABLED: "",
|
|
|
|
SLOW_SIMAPP50_ENABLED: "",
|
2021-10-22 00:08:06 +02:00
|
|
|
}),
|
2021-05-25 16:53:44 +02:00
|
|
|
new webpack.ProvidePlugin({
|
|
|
|
Buffer: ["buffer", "Buffer"],
|
|
|
|
}),
|
|
|
|
],
|
2021-04-14 17:35:53 +02:00
|
|
|
resolve: {
|
|
|
|
fallback: {
|
2021-05-19 17:46:21 +02:00
|
|
|
buffer: false,
|
|
|
|
crypto: false,
|
|
|
|
events: false,
|
|
|
|
path: false,
|
2022-02-27 13:16:47 +01:00
|
|
|
stream: false,
|
2021-05-19 17:46:21 +02:00
|
|
|
string_decoder: false,
|
2021-04-14 17:35:53 +02:00
|
|
|
},
|
|
|
|
},
|
2020-06-25 09:41:58 +02:00
|
|
|
},
|
|
|
|
];
|