diff --git a/packages/cosmwasm-stargate/global-variables.js b/packages/cosmwasm-stargate/global-variables.js new file mode 100644 index 0000000000..fdf77db086 --- /dev/null +++ b/packages/cosmwasm-stargate/global-variables.js @@ -0,0 +1,5 @@ +const process = { + env: { + TENDERMINT_ENABLED: 1, + } +}; \ No newline at end of file diff --git a/packages/cosmwasm-stargate/karma.conf.js b/packages/cosmwasm-stargate/karma.conf.js index 31c44e8edf..e13315aadc 100644 --- a/packages/cosmwasm-stargate/karma.conf.js +++ b/packages/cosmwasm-stargate/karma.conf.js @@ -15,7 +15,7 @@ module.exports = function (config) { frameworks: ["jasmine"], // list of files / patterns to load in the browser - files: ["dist/web/tests.js"], + files: ["./global-variables.js", "dist/web/tests.js"], client: { jasmine: { @@ -50,5 +50,13 @@ module.exports = function (config) { // Keep brower open for debugging. This is overridden by yarn scripts singleRun: false, + + webpack: { + plugins: [ + new webpack.ProvidePlugin({ + process: 'process/browser' + }) + ] + } }); };