Learning Android™ Application Programming: A Hands-On Guide to Building Android Applications
by James Talbot, Justin McLean, Jorge Hernandez
Refactoring Your Code
You’ll refactor a little code to optimize the application for testing. Refactoring the code provides peace of mind. If you make changes to the code, and the code still passes the tests, you can feel confident that you’ve not broken anything.
To optimize the code for the chapter, you must first do a little housekeeping.
1. Rename your project by right-clicking on the project name in the Package Explorer, selecting Refactor and Rename, typing On Your Bike - Chapter 10 in the New name field, and pressing OK. Make sure the Update references checkbox is checked.
2. Rename the com.androiddevbook.onyourbike.chapter9 package to com.androiddevbook.onyourbike.chapter10 by right-clicking on the package name, selecting Refactor and ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access