grafana/devenv/docker/loadtest-ts/webpack.config.js
Artur Wierzbicki 616db7f68b
Storage: k6 tests (#57496)
* object store k6

* update script

* refactor

* rename scripts

* fix paths

* fixes

* fix client - check connected state

* add teardown timeout

* rename to grpc object store client

* fail if health check fails

* abort rather than fail

* stale import

* create `run.sh`

* adjust for dummy server

* fix mkdir

* clean up dependencies

* remove name and version

* bring back name and version!

* remove clean webpackk plugin

* remove copy plugin

* update yarn lock

* remove stale import

* update yarn lock

* move perf tests to devenv/docker/loadtest-ts

* add codeownres
2022-10-27 23:22:04 +08:00

38 lines
809 B
JavaScript

const path = require('path');
const GlobEntries = require('webpack-glob-entries');
module.exports = {
mode: 'production',
entry: GlobEntries('./src/*test*.ts'), // Generates multiple entry for each test
output: {
path: path.join(__dirname, 'dist'),
libraryTarget: 'commonjs',
filename: '[name].js',
clean: true,
},
resolve: {
extensions: ['.ts', '.js'],
},
module: {
rules: [
{
test: /\.ts$/,
use: 'babel-loader',
exclude: /node_modules/,
},
],
},
target: 'web',
externals: /^(k6|https?\:\/\/)(\/.*)?/,
// Generate map files for compiled scripts
devtool: 'source-map',
stats: {
colors: true,
},
plugins: [],
optimization: {
// Don't minimize, as it's not used in the browser
minimize: false,
},
};