Such action shall be prosecuted in the same manner as if the plaintiff, at the time of commencing the action, had made an actual entry on the land demanded and had been immediately ousted by the defendant. In a trial upon the general issue, if the plaintiff proves that he is entitled to the estate set forth in the complaint and that he had a right of entry on the day when the action was commenced, he shall recover the land unless the defendant proves a better title in himself.
Mass. Gen. Laws ch. 237, § 5