§1. A person who by natural law and canon law is able freely to dispose of his or her goods can bestow goods for pious causes either through an act inter vivos or through an act mortis causa.
§2. In dispositions mortis causa for the good of the Church, the formalities of civil law are to be observed if possible; if they have been omitted, the heirs must be admonished regarding the obligation, to which they are bound, of ful-filling the intention of the testator.
Source: Code of Canon Law (Vatican.va)