Replacement for DalekJS (examples)
Hi Daniel. We are looking DalekJS replacement - to test JavaScript/HTML interaction. DalekJS is not updated anymore, not compatible with grunt 1.x, and prevents project dependencies from updating. I couldn't find any examples, but I found https://gitlab.com/distilled/distilled/issues/1 and since I need to ask a lot of question about Distilled anyway, I thought it may help to build up example base.
How would this DalekJS test look in Distilled?
module.exports = {
'v2 default-widget: readystatus should be ready': function(test) {
test.open('http://localhost:9537/test/v2/default-widget.html')
.waitFor(function() {
return !!document.querySelector('[data-gratipay-readystatus="ready"]');
}, [], 2000)
.assert.attr('[data-gratipay-teamslug]', 'data-gratipay-readystatus').is('ready', 'readystatus should be ready')
.done();
}
};
- https://github.com/gratipay/grtp.co/blob/master/test/v2/test_default-widget.js
- https://github.com/gratipay/grtp.co/blob/master/test/v2/default-widget.html
Code is public domain, so you can freely add it to project examples afterwards.