A Chinese city near the border with Myanmar has imposed a lockdown and started mass testing after three coronavirus cases were reported on Monday, with officials rushing to curb another outbreak.

It is the second time in four months that Ruili, home to more than 210,000 people, has been locked down after the discovery of cases imported from Myanmar.

Ruili is a major crossing point from Muse in neighbouring Myanmar, which has seen escalating unrest since a February 1 military coup, raising fears that people will try to flood across the border into China to escape the violence.

One of the three infected patients was a Myanmar national, according to health authorities in Yunnan province.

China closed the main bridge and crossing to Myanmar in March as cases surged across the border.

The Chinese city of Ruili (background) is a major crossing point from the town of Muse in Myanmar (foreground)
The Chinese city of Ruili (background) is a major crossing point from the town of Muse in Myanmar (foreground) AFP / Ye Aung THU

Authorities have also increased patrols in recent months to prevent illegal border crossings and cracked down on human trafficking to prevent an influx of refugees.

Ruili will test all residents for the virus within two days and all "non-essential travel" will be banned until further notice, the local government said Monday.

Only one member of each household can leave to buy daily necessities with permission during the testing period.

Anyone who wants to leave the city must produce a negative virus test conducted within the past 72 hours, the local government said.

The city tested all residents and urged everyone to get to vaccinated after a small outbreak in April.