There were plenty of infiltrators of the early christians who told authorities where masses were being said. The threat of arrest, fines or martyrdom does not absolve one of the duty to attend mass on Sundays.
Again, that is a different scenario, as those early Christians were not aware of which Priests were the traitors, but this time the Priests has made it known that they will be betrayed should the government asks for the list.
But you would be right if the Priests did not have the ushers taking names as you walked in the door, or if the faithful did not catch the secretary up in the choir loft taking names. But the faithful know in advance that they are being set up.