Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace phantom.args by system.args #215

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions Resources/js/run-qunit.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var system = require('system');

/**
* Wait until the test condition is true or a timeout occurs. Useful for waiting
* on a server response or for a ui change (fadeIn, etc.) to occur.
Expand Down Expand Up @@ -31,10 +33,9 @@ function waitFor(testFx, onReady, timeOutMillis) {
}
}
}, 100); //< repeat check every 250ms
};

}

if (phantom.args.length === 0 || phantom.args.length > 2) {
if (system.args.length === 1 || system.args.length > 3) {
console.log('Usage: run-qunit.js URL');
phantom.exit();
}
Expand All @@ -46,7 +47,7 @@ page.onConsoleMessage = function(msg) {
console.log(msg);
};

page.open(phantom.args[0], function(status){
page.open(system.args[1], function(status){
if (status !== "success") {
console.log("Unable to access network");
phantom.exit();
Expand Down