O'Reilly logo

Android Application Testing Guide by Diego Torres Milano

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Mock Objects

We visited the Mock Objects provided by the Android testing framework in Chapter 1, Getting Started with Testing and evaluated the concerns regarding not using real objects in order to isolate our tests from the surrounding environment.

The next chapter deals with Test Driven Development, and if we were Test Driven Development purists we may argue about the use of mock objects and be more inclined to use real ones. Martin Fowler calls these two styles the Classical and Mockist Test Driven Development dichotomy in his great article Mocks Aren't Stubs. It can be read online at http://www.martinfowler.com/articles/mocksArentStubs.html.

Independent of that discussion, we are introducing here the available Mock Objects as one of the available ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required