Skip to content

Commit

Permalink
fix(lib-test): reading compiled files
Browse files Browse the repository at this point in the history
  • Loading branch information
mkucharz committed May 25, 2018
1 parent f7fbe75 commit ad80095
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/lib-js-test/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ function run (endpoint, ctx = {}, params = {}) {
try {
let runFunc
if (mocks) {
runFunc = proxyquire(path.join(socketScriptsFolder, `${endpoint}.js`), mocks).default
runFunc = proxyquire(path.join(compiledScriptsFolder, `${endpoint}.js`), mocks).default
} else {
runFunc = require(path.join(socketScriptsFolder, `${endpoint}.js`)).default
runFunc = require(path.join(compiledScriptsFolder, `${endpoint}.js`)).default
}
output = runFunc({args, config, meta: socketMeta, HttpResponse, setResponse})
} catch (err) {
Expand Down
2 changes: 1 addition & 1 deletion packages/test-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"babel-preset-env": "^1.6.1",
"babel-register": "^6.26.0",
"rimraf": "2.6.2",
"standard": "10.0.3"
"standard": "^10.0.3"
},
"babel": {
"presets": [
Expand Down

0 comments on commit ad80095

Please sign in to comment.