SlideShare a Scribd company logo
1 of 46
Download to read offline
@ru_altom
Mobile Automation for
Unity Games
Ru Cindrea - Altom
@ru_altom
About me
and Altom
● started as a tester in 2002
● partner and software tester at Altom since 2008
○ software testing services
○ testing training - BBST series online
● into automation in general, mobile testing, mobile automation,
game testing and game development, specifically in Unity
@ru_altom
@ru_altom
About me
and Altom
● worked with Bitbar on using Bitbar Cloud for mobile games testing
using image recognition
● working on a concept development project developing apps with
Unity for fast prototyping
● working as an automation engineer for games
@ru_altom
@ru_altom
Game testing world
@ru_altom
● Fragmentation!
Mobile games: too many device + OS + screen resolution combinations to test manually
https://gs.statcounter.com/
Challenges with non-automated approach
@ru_altom
● Games are generally complex and testing all
functionalities manually becomes too time consuming
● Platform diversity - one codebase but testing-wise a lot of
ground to cover
Challenges with non-automated approach
@ru_altom
Options for Mobile Game Automation
@ru_altom
Unity Test Framework
@ru_altom
● Unity Test Runner with Edit / Play Mode
○ Great for unit testing and integration testing
○ Not suitable for end-to-end testing on target
devices/platforms
Unity Test Framework
@ru_altom
UI Automation
@ru_altom
@ru_altom
Works with Browserstack, Bitbar Cloud,
AWS and other Device Cloud platforms
Supports iOS and Android,
Mac, Windows
Testers who are familiar with
Selenium find it easy
Offers great interaction with
the target platform
Many programming languages
APPIUM
@ru_altom
@ru_altom
Click at coordinates
@ru_altom
Image Recognition
@ru_altom
Define “House” element using an image
@ru_altom
Define “House” element using an image
@ru_altom
OpenCV - Feature detection and matching
@ru_altom
OpenCV - Feature detection and matching
@ru_altom
OpenCV - Feature detection and matching
@ru_altom
Resolution Agnostic, works rotated and stretched items
@ru_altom
Resolution Agnostic, works rotated and stretched items
@ru_altom
Resolution Agnostic, works rotated and stretched items
@ru_altom
Resolution Agnostic, works rotated and stretched items
@ru_altom
● worked well for simple scenarios
● didn’t require any changes to the game
● found really useful issues
○ out of memory problems
○ crashes
○ graphics missing/not displayed correctly
Image Recognition + Appium
https://github.com/bitbar/testdroid-samples/tree/master/image-recognition
@ru_altom
● was not fast enough
● graphics change all the time in games
● didn't work well for apps that had a lot of text
● didn’t give enough granularity when it came to identifying objects
Image Recognition + Appium
https://github.com/bitbar/testdroid-samples/tree/master/image-recognition
@ru_altom
Beyond Image Recognition
@ru_altom
@ru_altom
@ru_altom
AltUnityTester
@ru_altom
Game/App
GamePlay Scene
MainMenu Scene
Obstacle
Cat
Start Button
Shop Button
@ru_altom
Game/App
GamePlay Scene
MainMenu Scene
Obstacle
Cat
Start Button
Shop Button
AltUnityTester
Prefab
AltUnityTester
Server
Port 13000
@ru_altom
Game/App
GamePlay Scene
MainMenu Scene
Obstacle
Cat
Start Button
Shop Button
AltUnityTester
Prefab
AltUnityTester
Server
socket connection
AltUnityTester
Bindings for: Works with: Editor
altUnityDriver = new AltUnityDriver(tcp_port = 13000);
Port 13000
@ru_altom
Game/App
GamePlay Scene
MainMenu Scene
Obstacle
Cat
Start Button
Shop Button
AltUnityTester
Prefab
AltUnityTester
Server
Load scene
{“scene”: “GamePlay”}
AltUnityTester
Bindings for: Works with: Editor
altUnityDriver = new AltUnityDriver(tcp_port = 13000);
altUnityDriver.LoadScene(“GamePlay”);
Port 13000
@ru_altom
Game/App
GamePlay Scene
MainMenu Scene
Obstacle
Cat
Start Button
Shop Button
AltUnityTester
Prefab
AltUnityTester
Server
Find “Cat”
{“el”: “cat”, “x”: 50, “y”: 60}
AltUnityTester
Bindings for: Works with: Editor
altUnityDriver = new AltUnityDriver(tcp_port = 13000);
altUnityDriver.LoadScene(“GamePlay”);
var cat = altUnityDriver.FindObject(By.NAME, “Cat”);
cat.Tap();
@ru_altom
AltUnityTester 1.0
https://gitlab.com/altom/altunity/altunitytester
@ru_altom
AltUnityTester 1.2
Appium Driver
@ru_altom
● worked well even for complex scenarios
● really fast and worked for all types of games
● tests are easier to maintain than with image recognition
AltUnityTester for Mobile Automation
https://gitlab.com/altom/altunity/altunitytester
@ru_altom
● requires a special / instrumented game build
● doesn’t work with all device cloud farms at the moment
AltUnityTester for Mobile Automation
https://gitlab.com/altom/altunity/altunitytester
@ru_altom
Struggles with UI Automation in Games
@ru_altom
● Every change in the code is tested
○ functional tests as automated scripts
○ give continuous feedback on how other parts of the
software are affected by the change
Traditional / Agile Software Development
@ru_altom
● QA team performs functional testing once features are
completed
● Playtesting, Alpha testing, Beta testing
Game Software Development
@ru_altom
● Small teams => no dedicated testers, developers don’t
have time to invest in automated tests
● Large teams => large teams of “manual” testers with not
enough coding skills
Struggles with UI Automation in Games
@ru_altom
● Make the tools more accessible to testers that have no
coding skills
● Offer support as much as possible
○ https://discord.gg/Ag9RSuS
● Keep the development engagement
Struggles with UI Automation in Games
@ru_altom
Keep the conversation going
@ru_altom
Thank you!
ru@altom.com

More Related Content

Featured

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Ru_Cindrea_Mobile_Automation_for_Unity_Games - Testing Assembly 2022.pdf