What is Robolectric? Uncover the features of Robolectric, how to setup Robolectric tests, and how to testing with Robolectric.
- [Voiceover] To this point in the course,…the tools that AP Eck Cover…are all part of the Android SDK.…The tools I'm about the cover over the next two videos…aren't part of the Android SDK.…They are open-source or free tools.…In this video, we take a brief look at Robolectric.…Robolectric is an open-source Android testing tool.…Its point of difference compared to other…Android testing tools is that it runs tests…on the development machines JVM,…not on a device or emulator.…
You might be thinking,…"Wait a minute!…Didn't Android SDS local test run on a JVM?"…Yes, local tests do run on the local JVM.…But local tests can can only test code…that have no Android ties.…Robolectric tests allow testers to test Android code…that is code that uses the Android API…on the JVM of the local machine.…How is Robolectric able to run tests on the JVM?…Robolectric provides a jar file, Android jar,…which is a collection of mock objects,…or what Robolectric calls shadow objects.…
Mock objects, something I teach you about…in the next chapter,…
AuthorJames P White
- Why unit test?
- Unit testing tools
- Local testing with JUnit
- Working with JUnit assertions, rules, and categories
- Executing instrumented tests
- Filtering tests
- Testing with UI Automator and other testing tools
Skill Level Intermediate
Foundations of UX: Usability Testingwith Chris Nodder1h 29m Beginner
1. Getting Started
2. Local Tests
3. Instrumented Tests
4. Other Android SDK Testing Tools
5. Mocking objects
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.