|
@@ -24,6 +24,8 @@ var cli = meow({
|
|
' --allow-domain Only allow requests to given (comma-separated) domains.',
|
|
' --allow-domain Only allow requests to given (comma-separated) domains.',
|
|
' --no-externals Block all domains except the main one.',
|
|
' --no-externals Block all domains except the main one.',
|
|
' --reporter The output format: "json" or "xml". Default is "json".',
|
|
' --reporter The output format: "json" or "xml". Default is "json".',
|
|
|
|
+ ' --local-storage Ability to set a local storage, key-value pairs (e.g. "bar=foo;domain=url")',
|
|
|
|
+ ' --session-storage Ability to set a session storage, key-value pairs (e.g. "bar=foo;domain=url")',
|
|
''
|
|
''
|
|
].join('\n'),
|
|
].join('\n'),
|
|
pkg: require('../package.json')
|
|
pkg: require('../package.json')
|
|
@@ -75,6 +77,10 @@ options.blockDomain = cli.flags.blockDomain || null;
|
|
options.allowDomain = cli.flags.allowDomain || null;
|
|
options.allowDomain = cli.flags.allowDomain || null;
|
|
options.noExternals = cli.flags.noExternals || null;
|
|
options.noExternals = cli.flags.noExternals || null;
|
|
|
|
|
|
|
|
+// Storage injection
|
|
|
|
+options.localStorage = cli.flags.localStorage;
|
|
|
|
+options.sessionStorage = cli.flags.sessionStorage;
|
|
|
|
+
|
|
// Output format
|
|
// Output format
|
|
if (cli.flags.reporter && cli.flags.reporter !== 'json' && cli.flags.reporter !== 'xml') {
|
|
if (cli.flags.reporter && cli.flags.reporter !== 'json' && cli.flags.reporter !== 'xml') {
|
|
console.error('Incorrect parameters: reporter has to be "json" or "xml"');
|
|
console.error('Incorrect parameters: reporter has to be "json" or "xml"');
|