Battery degradation is not linear. It's not like: 10 years = 70%, 20 years = 40%. It's probably closer to 20 years = 20 % capacity left. The decay becomes exponential-like after a relatively linear period of roughly 10 years.
If you want to get an idea, this is what the decay of battery capacity roughly looks like: https://www.researchgate.net/profile/Simon-Montoya-Bedoya-2/...
The Tesla warranty will fall under "first life" in the image in the link above.
So batteries (even Tesla Powerwalls) do degrade and do degrade to the point where you need to replace them a bunch of times during lifetime of a house.