Learn how to configuring your project for Android instrumentation testing, as well as execute instrumented unit tests in Android Studio and from the command line.
- [Voiceover] Executing your instrumented test…requires an Android device or emulator.…Use the AVD manager to create an AVD.…If you need help setting up your AVD…or connecting your physical device for testing,…see Android App Development Essentials for assistance.…With your AVD created or real device connected,…you can now execute instrumented tests.…To demonstrate how to execute instrumented tests,…I've started Android Studio…and opened project 03_02_start,…and, of course, started my AVD.…
I'm going to execute the instrumented test…created as part of the last video,…and I invite you to try the same.…First, locate SimpleMathTest in the Android test package.…Just as you executed a local test,…right click on the SimpleMathTest…and select run SimpleMathTest from the resulting menu.…This time, however, Android Studio knows you're running…an instrumented test, and it knows…that the test must execute on a real device or emulator,…so it displays the Select Deployment Target window…to allow you to select the device or emulator…
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
UX Foundations: 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.