The economy’s impressive resilience has helped markets shake off fiscal and geopolitical uncertainties.