You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 30, 2023. It is now read-only.
I want to run multiple tests in parallel using phantomjs tests (several of which register a random user and login/logout) which I am currently doing through the following nodejs script:
var processes = [];
async.eachLimit(files, 10, function(file, complete)
{
if (!file.match(/^(?!_).*(?:.coffee|.js)$/))
{
//only run files ending with .coffee or .js
//that do not start with an underscore
complete();
return;
}
var p = spawn('tools/phantomjs/phantomjs.exe', [
"build/phantomjs/" + file,
"--host=" + host
], {
cwd : "../.."
});
processes.push(p);
p.on('error', function (data) {
process.stderr.write(file + ':' + data);
exitCode = 1; //force run failure
complete(data + '');
});
p.stdout.on('data', function (data) {
process.stdout.write(file + ':' + data);
});
p.stderr.on('data', function (data) {
process.stderr.write(file + ':' + data);
});
p.on('close', function (code) {
if (code != 0)
{
//kill all the other phantomjs processes
//otherwise they will keep running until completion
_.each(processes, function(p) { p.kill(); });
process.stderr.write("Exiting tests with exit code: " + code);
process.exit(code);
}
console.log('child process exited with code ' + code);
complete();
});
});
However I get random errors which I believe to be because all the phantomjs's share the same cookiejar?
If I change async's foreach to only run tests 1 at a time the tests always succeed.
What I'm looking for is to start phantomjs in isolated mode so that it won't get the cookies from other phantomjs processes. Maybe chrome profiles could come to the rescue here somehow?
Has anybody run into this before?
The text was updated successfully, but these errors were encountered:
Due to our very limited maintenance capacity, we need to prioritize our development focus on other tasks. Therefore, this issue will be automatically closed (see #15395 for more details). In the future, if we see the need to attend to this issue again, then it will be reopened. Thank you for your contribution!
I want to run multiple tests in parallel using phantomjs tests (several of which register a random user and login/logout) which I am currently doing through the following nodejs script:
However I get random errors which I believe to be because all the phantomjs's share the same cookiejar?
If I change async's foreach to only run tests 1 at a time the tests always succeed.
What I'm looking for is to start phantomjs in isolated mode so that it won't get the cookies from other phantomjs processes. Maybe chrome profiles could come to the rescue here somehow?
Has anybody run into this before?
The text was updated successfully, but these errors were encountered: