How do you test the results of 'client.execute' in Nighwatch?
Nightwatch.js extends Node.js assert module, so you can also use any of the available methods there in your tests.
'some suite': function (client) {
client.execute(
function(greet){
return greet + " there!";
},
"Hello",
function(result){
client.assert.equal(result, "Hello there!");
}
);
}