dcrdata icon indicating copy to clipboard operation
dcrdata copied to clipboard

system testing: headless browser for Socket.io client tests

Open chappjc opened this issue 7 years ago • 0 comments

This complements the HTTP API stress testing issue https://github.com/decred/dcrdata/issues/913

It's important to test with something as close as possible to production. This means N wallet (e.g. Exodus) connections. Clearly not possible since we don't have code to hack on. But, it is likely that services use the reference socket.io package, so we should test that way, be it in node or a headless browser (rather than via a go client like we can for our API). Note that we have a simple test page that uses the socket.io client library: https://github.com/decred/dcrdata/blob/master/api/insight/test_socket.html

A candidate headless webkit browser with a Go API is webloop:

https://github.com/sourcegraph/webloop

As suggested by @degeri, headless Chrome or FireFox is a possibility. One avenue for this might be Selenium, which means https://github.com/tebeka/selenium (a Selenium/Webdriver client for Go) might be of use.

Any other viable approaches?

chappjc avatar Jan 05 '19 13:01 chappjc