Skip to content
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

Bootstrap Selenium based unit testing of remote protocols/UI + hook into Travis CI #16

Open
rib opened this issue Nov 24, 2015 · 0 comments

Comments

@rib
Copy link
Owner

rib commented Nov 24, 2015

Note: we've recently been considering the idea of using node.js for testing the remote protocol which should be able to share a lot of code with the web ui. It would probably be best to investigate simpler node.js based unit tests before looking into Selenium which would be more for testing the web ui itself.

I don't have any experience with Selenium so far, but it looks like a sensible starting point for being able to create unit tests for the web UI and - perhaps more importantly while there's barely much of a web UI too test yet - for the remote protocols.

I'd imagine we could have a test-ui.html + gputop-test.js that gets installed as an alternative to index.html + gputop-ui.js which wouldn't need to visualize anything but would exercise the protocols (JSON RPC + protocol buffers) involved in communicating between a device and web worker as well as between the front-end JS and web worker.

The code in gputop-ui.js can be referenced to see how the test should be able to interact with a device.

Note: It would probably be best to tackle this after gputop can generate fake, deterministic metrics as described in issue #15

This issue is about establishing the first unit test for the remote metrics protocols. A first test might open up a basic system wide metrics query and capture an overview of the metrics over one second and check that the received data is as expected.

The Travis Continuous Integration configuration (.travis.yml) should be updated to be able to run this first unit test routinely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant