Battery quality assessment