JUnit 5 Testing: Android Unidirectional Data Flow with LiveData.
Adam is working on Coinverse, the first crypto news app featuring audiocasts. Coinverse discovers crypto news, current events, and tech updates across the universe using AI driven filtering and creates audiocasts with neural networks for speech. Prior to Coinverse, Adam was a part of the Android team at eBay and worked on Mobile Ad Partnerships at Google. Outside of Android and crypto Adam enjoys tasting coffee from around the world, exploring health and wellness hacks, and traveling.
Beginning to test the Coinverse app from scratch was daunting at first. Where do I begin between testing the UI and business logic? How do I handle components that work with the network responses, databases, and analytics? After modularizing the app using Android's Unidirectional Data Flow (UDF) and LiveData, writing local unit tests for the business logic became simpler. This talk covers how to use the UDF pattern with LiveData in Kotlin in order to write JUnit 5 tests with MockK. | Sample Code - github.com/AdamSHurwitz/Coinverse | Google Play - bit.ly/play-coin