"Wir schaffen das" - or we will manage. Those were the words that Angela Merkel repeated to the German public when she swung open the doors to the country and allowed more than a million migrants in.

It was at this moment, that the doom-mongers declared the political sunset for Merkel. Throughout 2015 and 2016, headlines questioned the future of the chancellor. The Independent asked whether her refugee policy would "bring about her downfall?"

The Telegraph tried to explain how Germany had fallen "out of love with Angela Merkel".

Her open-door policy has been controversial throughout the country and across Europe, but ultimately has done little to damage Merkel's election prospects.

At first, in the summer of 2015, the country was seen as a bastion of hope as thousands of displaced migrants fled war-torn deserts to enter the Germany's booming economy.

Within a few weeks and months, questions were raised about the massive logistical challenge facing the country. It was the largest shift in German demographics for 25 years, since the fall of the wall. The numbers were huge, in less than a year, 900,000 people had come into the country, straining security services, healthcare and hostels.

Identifying the oncoming storm, Merkel set about steadying the ship, which had become increasingly rocky. A significant repatriation deal with Turkey has cut down on numbers from the near million that came in 2015 to 200,000 in 2016 and just 80,000 so far this year.

On top of this, stricter rules have led to an increased number of asylum seekers being deported on top of the thousands that have already left Germany to return home. Another major step has been integration.

Children were immediately placed into education. Now, new arrivals are often placed in a school within three weeks and they pick up the German language with relative ease.

Angela Merkel and Syrian refugees
German Chancellor and Christian Democrat (CDU) Angela Merkel poses for a photo with Syrian refugees after she spoke at an election campaign stop on September 19, 2017 in Schwerin, GermanySean Gallup/Getty Images

Many adults who come also need education, but this is more difficult. Adults cannot get a job in Germany unless they are granted asylum and, once this is accepted, those with the best prospects are placed into a compulsory integration course.

This includes 600 hours of German lessons and 100 hours of civic education. Another factor that helps is that Syrians, who make up the largest portion of those coming to the country, are often well educated.

According to numbers from the Federal Office for Migration and Refugees in Berlin, of the 135,000 Syrians who came to Germany in 2016, almost 80% had attended high school, technical school or university, with only 5% not having any education at all.

Those numbers vary from country to country. Almost 30% of all Iranians have arrived with a university degree, but around the same percentage from Afghanistan have no education whatsoever.

But even those with low levels of education or qualifications are settling into the workplace.

Of all the 18-64-year-olds who were registered in 2015, almost 80% of those have managed to get a job, a percentage that is higher than the national average.

The numbers are still a strain on the system, particularly for those working in immigration and asylum. Many officials now tasked with deciding on the asylum futures of thousands of migrants have only just been thrust into the job, and so the process is slow.

But despite this, the Germans are getting on with the job. The long-term effects of more than a million new immigrants will take several years to analyse. A new generation of students and people to the workforce will change the demography for the country for decades.

But for now, as Merkel said, they are managing.