When is basis for shares of ETF purchased by testamentary trust after DOD, but not distributed to heirs until later?

The decedent's estate was placed into a trust.  The trust purchased shares of mutual funds and ETFs a year after the DOD.  Shares were distributed to the heirs months later.  Is my "date of purchase" and cost basis determined by the date that I acquired the shares, or the date that the shares were purchased by the trust?