I injected jquery to casper :
phantom.injectJs('./utils/jquery/jquery-2.1.4.js');
but when I try to evaluate some jquery code, it is ignored: example:
function dragNdropAlertToActivity() {
var tt = casper.evaluate(function() {
$('div[id^="scheduler-alert-grid"] table:contains(BLUE ALERT)')[0].simulate("drag-n-drop", {
dragTarget: {
dx: 71,
dy: 71,
interpolation: {
stepCount: 2
}
}
});
return "done";
});
casper.echo(tt);
};
calling method like: casper.test.begin(function(){...}). test are executed using: casperjs test tests
Why it ignores jquery, even i write simple selector?
Aucun commentaire:
Enregistrer un commentaire