If you follow the book exactly as written, I’m unsure you can properly verify this challenge is implemented correctly. When you go to CrimeFragment, CrimeListFragment is destroyed. Upon returning to CrimeListFragment, a new view is created so visually there is no change. I’m also unsure if you measured any metrics regarding load time if you’d notice any change since a new RecyclerView is being created each time.
Here is how I verified it was working correctly, and the steps I went through:
I initially skipped the Ch. 12 Challenge and went through Ch. 18.
One of the sections that was removed from the 4th edition was the introduction of the two-pane layout with a List-Detail view. I implemented this for a landscape layout.
When in two-pane view, upon selecting an item from the CrimeListFragment, the CrimeFragment is loaded alongside so no Fragment or View is destroyed.
When the Crime details are updated, without the challenge the entire RecyclerView adapter is recreated and the entire list is reloaded. This results in the list going back to the top even if you are at the bottom of the scroll and you lose your place.
Once this challenge is completed properly, now only the list item that has changed reloads and the list stays at its current scroll point. Additionally, when a Crime is deleted (another prior challenge that was removed) the list item is removed from the RecyclerView and the items clean close the gap.
I just did notice a change when in the single-pane view as written in the book. If I check the box that the crime was solved (or not), when I now return to the list the solved image fades in/out. I don’t recall noticing this previously and don’t believe I changed anything related to the RecyclerView recently.
I can confirm this without the challenge on returning back to CrimeListFragment you are taken back to the top of the list as the whole list is reloaded but with the challenge you return back to the crime you clicked on. I’d say in terms of UX that’s how you’d test this challenge.