Permalink
Browse files

Fix incorrect line numbers in test failures

Reviewed By: voideanvalue

Differential Revision: D4597677

fbshipit-source-id: 9e10fb7aaee16cd902489cd95cfb04a151da2226
  • Loading branch information...
cpojer authored and facebook-github-bot committed Feb 22, 2017
1 parent ac29f45 commit 91b2dbb1dedc88d3724348db8972c43b8ececdc8
Showing with 4 additions and 6 deletions.
  1. +4 −6 jest/preprocessor.js
View
@@ -25,13 +25,11 @@ const transformer = require('../packager/transformer.js');
module.exports = {
process(src, file) {
// Don't transform node_modules, except react-tools which includes the
// untransformed copy of React
if (file.match(/node_modules\/(?!react-tools\/)/)) {
return src;
} else if (nodeFiles.test(file)) { // node specific transforms only
if (nodeFiles.test(file)) { // node specific transforms only
return babel.transform(
src, Object.assign({filename: file}, nodeOptions)).code;
src,
Object.assign({filename: file}, nodeOptions)
).code;
}
return transformer.transform(src, file, {inlineRequires: true}).code;

0 comments on commit 91b2dbb

Please sign in to comment.