Join Chiu-Ki Chan for an in-depth discussion in this video CustomTestRunner, part of Effective Android Testing for Mobile Developers.
- [Instructor] To use test recipe application…during test we will need a custom test runner.…Let's create that now.…Right click on the package name under Android Test…select New, Java Class…We will call it CustomTestRunner…Append dot test to the package name.…CustomTestRunner will extend Android J unit runner.…Extends AndroidJUnitRunner.…
To have the custom test runner extenuate…test recipe application instead of the normal recipe…application, we will need to override…the new application function.…Press control alt, and type NewApplication.…Press OK…Inside the body of NewApplication, in line 10,…we are going to keep the super core to NewApplication.…However we are going to replace the second perimeter from…className to test recipe application.…
So go ahead and replace that with TestRecipeApplication…dot class dot get name…To use the custom test runner we need to update…App slash build the gradle…Copy and paste the package name from here…and then go to gradle file.…In line 13 replace the TestInstrumentationRunner value…
- Why test?
- Local vs. on-device
- Code coverage
- UI testing
- Hermetic environment
- Dependency injection
- Testing with MVP
Skill Level Intermediate
1. Testing Considerations
2. Test as You Go
3. UI Testing
4. Hermetic Environment
5. Robot Pattern
- 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.