Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function initJasmine(context) {
context.setTimeout = function(fn, delay, params) { fn.apply(this, params); };
context.setInterval = function(fn, delay, params) { print('si');print(fn.toString());};
context.clearInterval = function(fn, delay, params) { print('ci');print(fn.toString());};
context.clearTimeout = function(fn, delay, params) { };
var jasmine = jasmineRequire.core(jasmineRequire);
var env = jasmine.getEnv();
var jI = jasmineRequire.interface(jasmine, env);
extend(context, jI);
var CoRep = jasmineRequire_console.ConsoleReporter();
env.addReporter(new CoRep({print: context.console.log, showColors: true}));
env.specFilter = function(spec) {
//print(spec.getFullName());
//for (var property in spec) print(property);
return true;
};
function extend(destination, source) {
for (var property in source) destination[property] = source[property];
return destination;
}
return env;
}