Testing has to be done while the light is on, otherwise there is no defect to be found. This is typical of worn brushes inside the alternator. They cause intermittent contact and intermittent loss of charging. The brush assembly costs about ten bucks and is pretty easy to replace. On some engines it can even be replaced without removing the alternator from the engine. Most people just replace the entire alternator. As the brushes continue to wear, the "Battery" light will turn on more often.