Car warranties are heading for 10 years these days. I think the two recent Chinese EVs we bought are both 7 or 8 year warranties. One must expect that this would affect second hand prices - but new prices seem to be coming down to a level where a second hand EV, in not many years, would be low enough that they are effectively throw away.
In this 'throw away' scenario, though, I'd hope that car recycling becomes a thing pretty quickly (aside: I think any large product manufacturer should have a complete lifecycle plan from manufacture to entire breakdown and recycle/reclaim, especially if their products include non-renewable minerals etc.)