WalmartLabs 自动化测试与持续集成的挑战及解决办法
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
MOBILE TEST AUTOMATION
Agenda
● Introduction
● Mobile Testing at WalmartLabs
○ Mobile Test Automation Solutions ○ How do we
■ achieve scale
■ present result
■ battle flakiness
○ Takeaways
● Q&A
Introduction - Why talk at MTSC ?
● A Technology Company
“ We're not a retailer competing in Silicon Valley. We're building an internet technology company inside the world's largest retailer. ”
● Multiple Apps covering different business: ○ Walmart
○ Sam’s Club
○ ASDA
○ Grocery
○ Vudu
○ ...
Introduction - Team
● Developer Experience Tools @WalmartLabs
● Provide all the mobile automation solutions across
multiple departments
Lillian Wang Chaoyi Chen
Technical Focus/Interest : iOS
Fun Fact : Always ready for being challenged in foosball. ✌Technical Focus/Interest : Mobile
Infrastructure
Fun Fact : Actually funnier than he
looks
Renas Reda
Technical Focus/Interest : Android.
Open source.
Fun Fact : As a kid I was addicted to
Nutella. I still have a few relapses
now and then :)
Testing at WalmartLabs - How and Why
Testing @WalmartLabs
● Used to have dedicated/centralized QA teams in charge
of all testings across different tracks
● Now only SDET, no manual QA.
● Developers responsible for contributing/maintaining test.
Testing @WalmartLabs
● scalable, robuts CI/CD
● easy to adopt test automation solutions
Testing @WalmartLabs - Overview
● Automation at “Walmart Scale” is hard
● How big is the workload?
○ avg runtime × #tests × #env × #browser/device ×#versions
● Need for a fast feedback, both locally and on CI ● 10 minute PR verify requirement
Testing @WalmartLabs - Mobile Overview
● We choose javascript client binding (WD.js)
○ Big reason: React Native
○ Node.js is one of the most popular/used languages at WalmartLabs
○ Aligns with our choice of web/api automation
● Caveats
○ WD.js: bad experience, lack of maintenance
● Kunlun (https:///package/kunlun) - a wrapper of WD.js ○ Easy to write test:
■ Easier for debug logging
■ Auto synchronization, no hard coded sleep()
■ Auto generate Page Object test structure
○ Easy to scale:
■ Magellan, SauceLabs and TestObject supports
■ Auto upload testing app
■ Configurable parallel simulators/devices/versions
■ Configurable failure retries
Kunlun overview
● Auto generate automation tests structure:
$ ./node_modules/.bin/kunlun init