TUNIS — The death this week of Tunisia’s first democratically elected president accelerated the timetable for choosing his successor, placing new strain on a political system in which power is shared among several parties, many voters are disillusioned and leaders are confronting a struggling economy.

But if the death on Thursday of President Béji Caïd Essebsi, at age 92, shook up the only surviving democracy to emerge from the Arab Spring, the system worked as planned. The usually divided Parliament made a swift, orderly transfer of power, voting with little drama or opposition to make its leader, Mohammed Ennaceur, the interim president.

“Everyone was sad but at the same time proud to be Tunisian,” said Watfa Belaid, an adviser to Prime Minister Youssef Chahed. “I think we showed the entire world that the institutions which were born from our revolution are rock solid and that they work. We did this in a peaceful way.”

But greater challenges lie ahead for a young democracy so fractious that the Constitutional Court remains vacant five years after it was established, because Parliament cannot agree on naming its members.