Long question, but it is one that we get all the time. Here is a step by step view of drilling out a cavity.

Tooth BEFORE Drilling Out Cavity ← This is a tooth prior to being worked on. There are no upon visual inspection. The cavity was located with x-ray.

Drilling Out Cavity - Step 1 ← As we drill into the tooth, we can see 2 things.

First, we see the yellowish color of healthy tooth. We know not continue drilling at that location. 

Second, we see the extreme white of a demineralizing tooth (cavity). We know to keep drilling at that location.

Drilling Out Cavity - Step 2 ← Here, we see that the white color is gone. This lets us know that we have reached the end of the cavity and have completed the drilling sequence of the procedure.

Tooth AFTER Drilling Out Cavity ← Here is the tooth in its final state. All the cavity is gone and the final filling is placed. And while the tooth is not “as good as new”, nothing ever can be.
It is as close as we can come to it.