Just about everything has been mentioned;
1. Measure voltage at rest. Meaning; disconnect battery after it's charged, let it sit 24 hours and measure the voltage. Should be 12.7 volts.
2. Check the electrolyte specific gravity. This assumes your battery is wet cell and not a sealed battery. Also assumes you have a quality tester and know how to safely measure and what is good or bad readings.
3. Load test the battery by putting a load on and checking the battery's ability to sustain the load without a disproportionate loss of voltage.
4. Replace the battery every 5 years as preemptive maintenance.
While I do perform steps 1, 2 and 3, I still also perform step 4 and just replace the thing. Seems a battery will always fail at the most inopportune time. Buying a battery on your time schedule allows you to shop for a sale, use a coupon, research what would be best for your application, etc.
I usually buy my batteries from Costco or Sams. Their return policy can't be beat; bring it in, get a new one. No hassle.