Session

Beyond mockery: Adventures in Android unit testing

The usual "one class = one unit" approach to unit testing lacks robustness. It produces brittle tests which need to be rewritten when you refactor. It encourages developers to simply rewrite their code as a test, meaning their tests mirror code bugs. And over-reliance on mocks significantly limits the breadth of the test.

This talk presents a different approach. By focusing on user interactions, not code units, we can optimise our testing and largely solve these problems.

Through concrete, practical examples we will learn:
- How to write robust tests which don't need rewriting when you refactor
- How to tailor tests to actions users perform, not specific code implementations
- Why fakes are often better than mocks

Tom Colvin

Android GDE, CTO at Apptaura

Basingstoke, United Kingdom

Actions

Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.

Jump to top