Stabilized power supply to test battery capacity