Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Disable source-map-support import during jest tests as it breaks line…
Browse files Browse the repository at this point in the history
… numbers (#21)
  • Loading branch information
jeanregisser authored Apr 3, 2020
1 parent 6081640 commit 3dbc32b
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
4 changes: 3 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// make sourcemaps work!
require("source-map-support/register");
if (process.env.NODE_ENV !== "test") {
require("source-map-support/register");
}

const debug = require("debug")("ganache");

Expand Down
4 changes: 3 additions & 1 deletion lib/provider.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// make sourcemaps work!
require("source-map-support/register");
if (process.env.NODE_ENV !== "test") {
require("source-map-support/register");
}

let ProviderEngine = require("web3-provider-engine");
let SubscriptionSubprovider = require("web3-provider-engine/subproviders/subscriptions");
Expand Down
4 changes: 3 additions & 1 deletion lib/server.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// make sourcemaps work!
require("source-map-support/register");
if (process.env.NODE_ENV !== "test") {
require("source-map-support/register");
}

var Provider = require("./provider");
var webSocketServer = require("./webSocketServer");
Expand Down
4 changes: 3 additions & 1 deletion public-exports.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// make sourcemaps work!
require("source-map-support/register");
if (process.env.NODE_ENV !== "test") {
require("source-map-support/register");
}

const Provider = require("./lib/provider");
const Server = require("./lib/server");
Expand Down

0 comments on commit 3dbc32b

Please sign in to comment.