-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

Selenium Design Patterns and Best Practices
By :

The Black Hole Proxy pattern tries to reduce test instability by getting rid of as many third-party uncertainties as possible. Modern websites have a lot of third-party content loaded on every page. There are social networking buttons, images coming from CDNs, tracking pixels, and much more. All of these items can destabilize our tests at any point. Black Hole Proxy takes all HTTP requests going to third-party websites and blocks them, as if the request was sucked into a black hole.
Web pages that have heavy traffic in the production environment tend to cache their JavaScript and the cached assets on a third-party CDN. When testing an environment such as production, we should not be blocking critical assets but allowing them to be properly loaded using the proxy whitelist feature.
Black Hole Proxy brings many advantages to our tests:
Improved speed: Since the web applications we test tend to be on the local network...
Change the font size
Change margin width
Change background colour