If you would lose, you would have no Pokemon to continue with. S you can just get thrugh the route by losing?
I don't think they would ever do that.
Maybe after the player loses, the rival can heal the players Pokemon. It's not too far fetched considering Cheren would heal our Pokemon every so often throughout Black and White.