Easiest is to read any diagnostic fault codes with a scanner that can access the ABS computer. It constantly monitors the sensors for continuity and the proper resistance. A code will be set if the two wires are shorted together, either wire is shorted to ground, or one of them is open. Mechanical items are tested while driving. Metal filings on the sensor's magnet or a missing tone ring will cause a complete loss of signal which will be detected when the computer sees three good signals from the other sensors. A cracked tone ring will produce one extra pulse per wheel revolution and will be recognized as a problem after a few hundred feet to as much as a mile or more.
Depending on the problem and the code set in memory, the yellow warning light could go off while you're driving or it could "latch" on and not go off until you stop and restart the engine, even if the intermittent problem went away. Even when the light goes off, the codes remain in memory. On many older systems those codes could not be erased by disconnecting the battery. You had to have the scanner to erase codes. On some newer systems disconnecting the battery or running it dead will erase the codes. It's important to not disconnect the battery until those codes have been read, otherwise you will lose that valuable information.