How we improved our iOS CI infrastructure with observability tools
Article Summary
Grab's iOS team turned flaky CI tests into a 50% CPU reduction story. Their secret? Observability tools and some creative workarounds for Xcode 13.1's notorious Spotlight bug.
When Grab upgraded to Xcode 13.1, their iOS CI infrastructure became unstable with high CPU usage and unreliable UITests. Instead of waiting for Apple's fix, the team integrated observability tools to diagnose and solve the issues themselves across their superapp's massive test suite.
Key Takeaways
- Moved Spotlight.app during tests to cut CPU usage by 50%+
- Built mock browser for deep link tests, reducing CI time by 20%
- Booted simulators with pre-granted permissions for 5% faster execution
- Custom network monitoring tool caught unintentional internet downloads during tests
- Modified retry rules to reduce manual engineer intervention without increasing flakiness
Grab achieved 20% faster CI times and 50% lower CPU usage by treating their test infrastructure as a system that needs monitoring, not just maintenance.
About This Article
Grab's iOS team found that over 10% of their test suite was deep link tests. These tests depended on iOS Safari, which slowed down test execution and made the results less reliable across their superapp platform.
The team built a mock browser for UITest that captured URLs passed as launch arguments and ran them locally instead. This removed the need for Safari entirely by using custom test infrastructure.
CI time dropped by 20% and test stability improved because Safari was no longer part of the critical path.