-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resolves #207 - Adding automated tests to CI #213
Conversation
tests/selenium.spec.js
Outdated
|
||
// clear all data | ||
await clickByCss("#clear-all-data"); | ||
await driver.sleep(1000); // wait for all collections to be cleared |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we wait for a certain selector instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem here is it marks the rows as busy/ready one at a time, so the waitForLoad
call doesn't work reliably as it's a race condition. Maybe we could use DOMAttrModified
events and give ourselves a debounce so we wait 200ms after the last busy is removed? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Switched to a debounce timeout that relies on a MutationObserver
. It's kinda ugly. It has to inject an element to work because I don't see a way to pipe those events out of the browser (there appears to be a chrome option but no firefox option).
But, it seems to work perfectly. I tried to make the code as readable as possible.
Resolves #207 - adding automated tests to CI pipeline.
This is adding selenium tests that we can run to have confidence in our changes before merging and/or running against a dev firefox branch.
ToDo:
Notes: