<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Gloria Chen on Medium]]></title>
        <description><![CDATA[Stories by Gloria Chen on Medium]]></description>
        <link>https://medium.com/@gloriamchen?source=rss-1af4c9a6929a------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*ufLRshV2IOvaAa5c.</url>
            <title>Stories by Gloria Chen on Medium</title>
            <link>https://medium.com/@gloriamchen?source=rss-1af4c9a6929a------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 19:48:07 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@gloriamchen/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Up-level your web automation using Selenium Grid with Docker]]></title>
            <link>https://medium.com/levers-fulcrum/up-level-your-web-automation-using-selenium-grid-with-docker-c1cda248a4e3?source=rss-1af4c9a6929a------2</link>
            <guid isPermaLink="false">https://medium.com/p/c1cda248a4e3</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[qa]]></category>
            <category><![CDATA[selenium]]></category>
            <dc:creator><![CDATA[Gloria Chen]]></dc:creator>
            <pubDate>Fri, 02 Jun 2017 20:07:23 GMT</pubDate>
            <atom:updated>2017-06-02T20:07:23.165Z</atom:updated>
            <content:encoded><![CDATA[<p>As a quality engineer who’s responsible for testing web applications, Selenium WebDriver is arguably the most popular solution for automation. However, using a single WebDriver on a local machine soon becomes insufficient in many ways:</p><ol><li><strong>Tests are slow</strong>: browser tests are slow compared to unit or integration tests, and when you’re running Selenium tests serially in a single process, running your test suite soon becomes an excuse for a very lengthy nap.</li><li><strong>Tests are more flaky</strong>: when running tests locally, WebDriver actually launches a browser driver, meaning if you’re running your tests with the ChromeDriver, a chrome browser opens up and takes over focus on your mouse and inputs. If you try to do anything else, focus on any other windows or processes outside of the test run, this could cause failures in your test suite if it draws away the input focus.</li></ol><p>Automated tests are only useful if they <em>provide confidence</em> that our ever-growing list of features are free from regressions and working as expected. Once the test suite becomes flaky or takes more than a reasonable amount of time to run, tests soon lose their value to the team.</p><p>To enable the engineers to run the automation test suite in a more consistent and timely manner, we began looking into different tools to help scale our web automation. This is where Selenium Grid and Docker come in.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*t8pcwEqSYkuU0JY9xog17g.jpeg" /></figure><p><strong>Selenium Grid</strong> enables us to do distributed testing, allowing us to perform test execution on different machines, with multiple browsers at the same time. We can point our tests against a central hub, which will then distribute the execution to remote nodes. However, setting up our own Selenium Grid means we have to configure browsers across multiple machines, virtual or physical, and making sure each machine is running the Selenium Server correctly. This also means maintaining the Grid and making updates would be a time-consuming, node-by-node process. This is where <strong>Docker</strong> comes in and saves the day!</p><p><strong>Amazon ECS with Docker</strong></p><p>Docker provides a central point from where we can configure and update our Selenium Grid hub and nodes, <em>and</em> gives us a way to quickly recover in case a node ends up in a bad state; and <a href="http://docs.aws.amazon.com/AmazonECS/latest/developerguide/Welcome.html">Amazon ECS</a> provides a ‘highly scalable, fast, container management service that makes it easy to run, stop, and manage Docker containers on a cluster of EC2 instances.’ At Lever, we are already using Amazon ECS for cluster and configuration management for most of our deployments, so it became the obvious service for us to use for spinning up our Selenium Grid cluster using Docker containers.</p><h3>So how did we set this up?</h3><p>We created an ECS cluster for Selenium Grid, and within the task definition, specified the Docker container images to pull and run across the cluster. We are using the Docker images for Selenium Hub and Node configurations with Chrome found in the<a href="https://github.com/SeleniumHQ/docker-selenium"> docker-selenium</a> repository. We decided to start our Selenium Grid configuration with five Chrome nodes, so we specify a container for the Hub, and 5 Chrome Node containers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ECsnLSr6WHxzHdCS." /><figcaption>ECS container definitions for Grid</figcaption></figure><p>After specifying the images in our ECS task definitions, we start up the Selenium Grid cluster, which should now have one hub and five Chrome nodes. With each node setup to have 10 instances of Chrome available for use!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*R6fXdpuSvnVC24WpI06Lqw.png" /><figcaption>Selenium Grid web console shows 5 chrome nodes</figcaption></figure><p>Using Docker to spin up our automation cluster has been one of the best decisions we’ve made. Docker let’s us take our images and spin them up as a pre-configured Selenium Grid cluster. A huge benefit is its <em>ability to scale</em>.</p><p>Another added benefit to running Selenium Grid with Docker is the ability to restart the entire grid. Nodes in Selenium Grid often end up in a bad state if left up and running for a long enough time, when this happens, we can save a lot of the diagnostic overhead by just restarting the grid. With Docker Compose, that takes just a couple of minutes.</p><p>Since moving off of running Selenium locally, the Quality Team at lever has managed to improve test stability, as well as reduce the total automation runtime by 93%! If you are thinking about using Selenium Grid for testing your web-based application, Docker can be a great way to improve your productivity.</p><p>While we’ve made significant improvements to test stability and runtime, we are still far from achieving our goal of having a seamless test and release process. If that seems like an interesting challenge for you, please check out our <a href="https://jobs.lever.co/lever">jobs page</a>!</p><p>This post was edited with the help of <a href="https://medium.com/u/a1a49583183">Leighton Wallace</a>, <a href="https://medium.com/u/a0bf921aab9a">Meaghan Lewis</a>, and <a href="https://medium.com/u/aa03d612b8c7">Rachael Stedman</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c1cda248a4e3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/levers-fulcrum/up-level-your-web-automation-using-selenium-grid-with-docker-c1cda248a4e3">Up-level your web automation using Selenium Grid with Docker</a> was originally published in <a href="https://medium.com/levers-fulcrum">Lever Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>