Stryker

stryker-cli.js - Stryker report

Summary

File
Mutation score
# Killed
# Survived
# Timeout
# No coverage
# Errors
Total detected
Total undetected
Total mutants
stryker-cli.js
0%
0/9 0 0 0 9 0 0 9 9

Code

"use strict";
var program = require('commander');
var ConfigReader_1 = require('./ConfigReader');
var Stryker_1 = require('./Stryker');
var log4js = require('log4js');
var log = log4js.getLogger('stryker-cli');
function list(val) 0{
    return val.split(',');
}
program
    .usage('-f <files> -m <filesToMutate> -c <configFileLocation> [other options]')
    .description('Starts the stryker mutation testing process. Required arguments are --files, --testFramework and --testRunner. You can use globbing expressions to target multiple files. See https://github.com/isaacs/node-glob#glob-primer for more information about the globbing syntax.')
    .option('-m, --mutate <filesToMutate>', "A comma seperated list of globbing expression used for selecting the files that should be mutated.\n  Example: src/**/*.js,a.js", list)
    .option('-f, --files <allFiles>', "A comma seperated list of globbing expression used for selecting all files needed to run the tests. These include library files, test files and files to mutate, but should NOT include test framework files (for example jasmine). For a more detailed way of selecting inputfiles, please use a configFile.\n  Example: node_modules/a-lib/**/*.js,src/**/*.js,a.js,test/**/*.js", list)
    .option('--coverageAnalysis <perTest|all|off>', "The coverage analysis strategy you want to use. Default value: \"perTest\"\n  * \"off\": Stryker will not determine the covered code during the initial test run fase. All tests are always tested for each mutant during the mutation testing fase.\n  * \"all\": Stryker will determine the covered code of all tests during the initial test run fase. Only mutants that are actually covered by your test suite are tested during the mutation testing fase.\n  * \"perTest\": Stryker will determine the covered code per executed test during the initial test run fase. Only mutants that are actually covered by your test suite are tested during the mutation testing fase. Only those tests that cover the mutant are tested per mutant.")
    .option('--testFramework <name>', "The name of the test framework you want to use.")
    .option('--testRunner <name>', "The name of the test runner you want to use")
    .option('--reporter <name>', 'A comma separated list of the names of the reporter(s) you want to use', list)
    .option('--port <n>', 'A free port for the test runner to use (if it needs to). Any additional test runners will be spawned using n+1, n+2, etc', parseInt)
    .option('--timeoutMs <number>', 'Tweak the absolute timeout used to wait for a test runner to complete', parseInt)
    .option('--timeoutFactor <number>', 'Tweak the standard deviation relative to the normal test run of a mutated test', parseFloat)
    .option('--plugins <listOfPlugins>', 'A list of plugins you want stryker to load (`require`).', list)
    .option('-c, --configFile <configFileLocation>', 1'A location to a config file. That file should export a function which accepts a "config" object\n' +
    ConfigReader_1.CONFIG_SYNTAX_HELP)
    .option('--logLevel <level>', 'Set the log4js loglevel. Possible values: fatal, error, warn, info, debug, trace, all and off. Default is "info"')
    .parse(process.argv);
log4js.setGlobalLogLevel(2program['logLevel'] || 'info');
// Cleanup commander state
delete program.options;
delete program.rawArgs;
delete program.args;
delete program.commands;
for (var i in program) 3{
    if (456i.charAt(0) === '_') 7{
        delete program[i];
    }
}
new Stryker_1.default(program).runMutationTest()
    .catch(function (err) 8{ return log.error("an error occurred", err); });
//# sourceMappingURL=stryker-cli.js.map