Arik Lerner, Automation Team Leader, and Waseem Hamshawi, Automation Infra Developer, present how to build a large scale automated testing platform by leveraging containers orchestration over GCP, with the ability to scale out and provide fast feedback while maintaining a highly reliable test infrastructure.
The presentation includes new approach of managing a scalable testing platform of distributed automated tests with Kubernetes and Docker over Google Cloud Platform.
Topics:
• GCP and Kubernetes introduction for automated testing
• Traditional Selenium Grid vs Selenium Standalone with Kubernetes and Docker for Web and Mobile tests
• Distributed and containerized testing environment over container cluster - different use cases
Ephemerals - "Short-lived Testing Endpoints". An Open Source by LivePerson which makes automation testing at large scale like a "Walk in the park".
SpotFlow: Tracking Method Calls and States at Runtime
Kubernetes your tests! automation with docker on google cloud platform
1. By Arik Lerner & Waseem Hamshawi
Kubernetes your Tests!
Testing with Docker on Google Cloud Platform
The JourneyBased On True Story!
2. {
“Name”: “Arik Lerner”,
“Role”: “Automation Infra Team Leader at LivePerson”,
“Data”: [
“3 years as Team Leader in Liveperson” ,
“2 years Java developer Reporting Platform Liveperson”
],
“Hobbies”: “Private pilot”
}
Active Prevention Department
3. {
“Name”: “Waseem Hamshawi”,
“Role”: “Senior Automation Infra Developer at Liveperson”,
“Data”: [
“2.5 years at Liveperson”,
“github: waseemh.github.io”,
],
“Hobbies”: “Running”
}
Waseem is Here!
Active Prevention Department
5. ❏ Fast feedback
❏ Stable Environment
❏ Isolation
❏ Investigation tools - Hard to support (Video/HAR)
❏ Scale
❏ Efficiency
❏ Browser diversity
❏ Mobile Support
Requirements
6. Selenium Hub
Running Test
Static VMs
Supported Requirements
Browser diversity
Mobile Support
Parallelism
Traditional Selenium Grid
9. Cattlevs.Pets
VM
Container
● When they get ill you nurse them back
to health
● You name them! And take of them!
● When they get ill you get another one!
● They are almost identical to one another
● Don't have specific names. Given numbers
● Can be simply replaced if they die
10. What Docker gives us ?
● Build it once run it everywhere!
● Resource Isolation
● Test Isolation
● Package format
● Implementation of a container
Docker
15. We need more than just Packaging and
Isolation:
● Orchestration - Distribute containers
● Health Checks
● Resilience and Self-healing
● Scaling - making jobs bigger or smaller
Kubernetes Orchestrator
18. Benefits of Cloud Platform
● Kubernetes cluster in a click of a button (GCP)
● No idle machines - Use when needed
● Costs per build/test - measurable
● Not part of Liveperson network
● Geolocation simulation
23. Requirements
❏ Fast feedback
❏ Stable Environment
❏ Isolation
❏ Investigation tools - Hard to support (Video/HAR)
❏ Scale
❏ Efficiency
❏ Browser diversity
❏ Mobile Support
26. waseemh-mac$ java -jar selenium-server-standalone-2.53.1.jar -role
Selenium server can run in one of the following roles:
hub as a hub of a Selenium grid
node as a node of a Selenium grid
standalone as a standalone server not being a part of a grid
Test Hub
Selenium Server
(Node)
Selenium Standalone
27. Non-Grid Solution
● Fast → Deploy Selenium Standalone containers on-demand
● Short-lived → Selenium containers are destroyed once test ends
● Distribute and manage containers with Kubernetes
Test
createRemoteWebDriverSession(caps)
VM
VM
VM
VM
new RemoteWebDriver(External Endpoint)