Why when I use console.log
in evaluate
, it works:
casper.then(function() {
this.evaluate( function() {
console.log('hello');
});
});
But this doesn't work:
casper.then(function() {
this.evaluate( function() {
setTimeout( function() {console.log('hello');}, 1000);
});
});