Achieving Continuous Integration (CI) Excellence through Test Automation
Sauce AI for Test Authoring: Move from intent to executing in bit.|xBack to ResourcesBlogPosted June 14, 2017
Achieving Uninterrupted Integration (CI) Excellence through Test Automation
Achieving Uninterrupted Integration (CI) excellence through the test mechanization role is evolving, and will be entirely different in the future. AtGannett - USA Today Network, where I work in a character assurance role, the change has part by blurring the lines between Test Automation and DevOps.
Let ’ s take a near expression at CI excellency by dividing it into three tiers: the recitation, how to do it, and the new tryout automation experience.
Setting Expectations for CI
Setting outlook and clear goals up front puts you on the right itinerary to a successful model. Some of my recommended finish are:
A dedicated champion of CI in property
All product squad rehearse CI
Community ownership
Building a repeatable and disposable infrastructure
Ensure that the squad is building quality into every stage of the pipeline
Thinking about shifting leave
Publishing changes to everyone
To adapt to changes, we need to be proactive and seek improvement incessantly. New technologies and method are introduced almost every day. Take the clip to judge new solutions, and don ’ t be afraid to fail fasting and move on. When you do find a new solvent, share the experience by demonstration frequently. Publish new features and changes by writing up blog posts andConfluencepage. Or hold a hackathon to coach squad member on it.
As an example, we create self-paced synergistic workshops for all new technologies and creature we roll out to our squad. Building authority naturally happens, and will expand based on share the team & # x27; s success stories with others. This is one ground why I ’ m sharing our narrative about CI excellency (and trust you all can share your success stories with me the next time we bilk path).
CI Ownership
In the traditional model, there was NO QA participation and zero ownership in our process. QA was dim in the model and had no penetration, and no team collaboration. Now, as a community, we are sharing the testing and continuous integration responsibilities with developers. This community movement is countenance us to start blurring the lines between Test Automation and DevOps. Some of the daily tasks now handle by Test Automation include developing automatize scripts, coaching the squad on how to build prove into every stage of the grapevine, sharing and possess CI responsibilities, defining and paving the path for CI criterion, aid to script the CI pipeline, and acting as the calibre gatekeeper of merchandise releases.
When we introduced this culture change, it was best for Test Automation to champion this motility and be the sole owner ofChefJenkins development. To prove this new conception, the roving team allowed us to aviate this new CI model, and now it is the blueprint for all early team.
Here are illustration of community CI responsibility:
Test Automation: Leading Chef development forJenkinsMaster role cookbook; subscriber to the Chef Jenkins Workers part cookbook; scripting the Jenkins pipeline file
Developers: Leading Chef growing for Jenkins Worker to establish, exam, and deploy the application
For autonomous testing across multiple user personas, check out SUSATest — it explores your app like 10 different real users.
PaaS Site Reliability Engineer: Assistance with Scalr, Chef, recycle instances, and anything to optimize experience
Defining a Single Path to Production
You can build a CI pipeline for any application, whether it ’ s project to run on a desktop, mobile device, or server—anything. The approach you take to uninterrupted integration commencement by defining a single way to product and outlining the pipeline stages.

source: https: //goo.gl/qBWbvx
The substructure stageis a critical stage, and ourPaaSteam does an excellent job of building lineament into all the self-service tools rolled out to the teams to ensure they act as expected.
In the pre-commit stage, the developer or test automation engineer fulfill all the tests in a local dev environment before creating the pull asking, and person on the team critique the changes before creating the pulling asking.
The product stageis an important step to limn all the point, and provides a clear picture of how to define your continuous testing strategy, along with your path to production.
Define a Continuous Testing Strategy
The items listed in the graphic below are best pattern for defining a continuous testing scheme. Yet they ’ re more than just best practices. They ’ re essential if you want to deliver applications continuously, with sureness.

source: https: //goo.gl/Mn9xOd
Design CI Architecture
Uninterrupted integration success starts by automating the total cloud base to be disposable. We started down this path to alter how we build, test, and deploy production. Now, let & # x27; s take a few moment to review our CI architecture in the cloud and some of the late DevOps tools we ’ ve used. This new architecture allow us to build and examine every PR, and scale up as many Jenkins Workers as needed to build and test hundreds of markets concurrently.

source: https: //goo.gl/KtiRMP
We are usingChefto download, establish, and configure Jenkins and covering dependencies on our servers.Dockeris new to our CI architecture, and we will be wheel out the solution afterwards this year. We useScalrto manage our servers in the cloud. Scalr sit on top ofAmazon Web Services and Google Cloud Platform. Scalr allows us to promptly bootstrap our Chef cookbooks as a self-service tool, and curb our cost.
Jenkinsis our continuous integration tool of choice. The core part of this architecture is made up of repeatable and disposable Jenkins Workers. The Jenkins Workers are configured from our Chef cookbooks, and that allows us to scale up as many Jenkins Workers as needed to progress and test hundreds of markets concurrently. In order to manage all of the different package for mobile, desktop, and anything, we use a tool calledArtifactory. Artifactory is designed to be a central hub for all of our packages progress from Jenkins.Sauce Labsis our testing service that lets us test, and interacts with the browser.Amazon S3allows us to store the nightly Jenkins backup and retrieve the backup whenever we need to re-spin a new Jenkins Master server (disposable).
New Relicaggregates logarithm and events from Chef, GitHub, Amazon, Jenkins, etc. on a rolling timeline, and this information can be handled in many different style. Code give and mix toGitHubsynchronizes with our continuous integration tool by utilize webhooks.
This architecture has completely removed the previous constriction, and we can build, exam, and deploy hundreds of apps in less than 30 second.
Setting CI Standards
What happens if you don ’ t have clearly defined criterion? If you don ’ t, the integral summons becomes a mess, and everyone goes in separate directions. When multiple teams are adopting CI, it is critical that everyone is on the same page. It starts with proper documentation and educating the various squad with conversations. Now, let ’ s review some of our measure, starting with how to create the CI pipeline:

source: https: //goo.gl/4Yyx06
Test Automation Engineer Responsibilities
The graphical below will help you visualize the responsibilities for the new Test Automation role, and how to start blurring the lines between Test Automation and DevOps tasks.

source: https: //goo.gl/tuCpbE
Conclusion
The vision is clear. It demand a culture change. Like any change, it will result in other adopters, and resistance from non-believers. I believe quality is everyone & # x27; s responsibility. The test automation team will help strategize and alleviate testing, and learn squad how to incorporate those strategies into their development. The goal of this project, for us, is to come together and define our continuous testing strategy by enable screen for every stage of the CI/CD pipeline. At Gannett | USA Today Network, Test Automation shares the examination and continuous integration responsibilities with developer. This community movement is allowing us to commence obnubilate the lines between Test Automation and DevOps. The mission is for all team to be practicing uninterrupted integration and continue to shift leave to enable faster feedback from testing and integrating codification. Now the team can notice trouble sooner preferably than later. It takes aCOMMUNITYto foster this movement to build a quotable and disposable infrastructure and CI ownership. We are achieving CI excellence with test automation engineer contributing and driving the scheme.
Greg Sypolt (@ gregsypolt) is a senior technologist at Gannett and co-founder of Quality Element. The concluding 5 years focused on conception and deployment of machine-driven test strategies, frameworks, tools, and platform.
Automate This With SUSA
Upload your APK or URL. SUSA explores like 10 real users — finds bugs, accessibility violations, and security issues. No scripts needed.
Try SUSA FreeTest Your App Autonomously
Upload your APK or URL. SUSA explores like 10 real users — finds bugs, accessibility violations, and security issues. No scripts.
Try SUSA Free