Skip to content

Commit

Permalink
fix prod tests
Browse files Browse the repository at this point in the history
  • Loading branch information
runspired committed Apr 12, 2017
1 parent 48c0f03 commit dccceb5
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,14 @@ for (var i = 0; i < args.length; i++) {
break;
}
}

process.env.INSTRUMENT_HEIMDALL = INSTRUMENT_HEIMDALL;

function add(options, name, array) {
var option = options[name] = options[name] || [];
option.push.apply(option, array);
function isProductionEnv() {
var isProd = /production/.test(process.env.EMBER_ENV);
var isTest = process.env.EMBER_CLI_TEST_COMMAND;

return isProd && !isTest;
}

module.exports = {
Expand Down Expand Up @@ -117,7 +120,8 @@ module.exports = {
dir
]));

if (/production/.test(process.env.EMBER_ENV)) {
if (isProductionEnv()) {
console.log('is prod');
tree = new Funnel(tree, {
exclude: [
/-private\/debug\.js/
Expand Down

0 comments on commit dccceb5

Please sign in to comment.