Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function BabelAssertionVisitor (babel, matcher, options) {
this.babel = babel;
this.matcher = matcher;
this.options = options;
this.currentArgumentNodePath = null;
this.argumentModified = false;
this.valueRecorder = null;
this.locationDetector = new EspowerLocationDetector(this.options);
var babelTemplate = babel.template;
this.helperTemplate = babelTemplate(helperCode);
var whiteListWithRange = Object.keys(options.astWhiteList).reduce(function (acc, key) {
acc[key] = options.astWhiteList[key].concat(['range']);
return acc;
}, {});
this.purifyAst = cloneWithWhitelist(whiteListWithRange);
}