-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
30 lines (25 loc) · 772 Bytes
/
index.js
File metadata and controls
30 lines (25 loc) · 772 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
exports.summary = 'Page Loading Reporter';
exports.usage = '<url> [options]';
exports.options = {
"url" : {
describe : 'the URL of the destination site to load test'
},
"task": {
describe: "the task to perform"
},
"config": {
describe: "a local configuration file of further loadreport settings"
}
};
exports.run = function (options, done) {
var url = options.url;
var task = options.task;
var config = options.config;
debugger;
var phantomjs = exports.loadTask('mod-phantomjs');
var path = require('path');
phantomjs.run({
script: path.join(__dirname, "loadreport.js"),
args: [url, config || path.join(__dirname, "config.json"), __dirname, task || '']
}, done);
};