From Talmud Yoma 28b
Apropos the previous statement, the Gemara cites that Rav said: Abraham our Patriarch fulfilled the entire Torah before it was given, as it is stated: “Because [ekev] Abraham hearkened to My voice and kept My charge, My mitzvot, My statutes and My Torahs” (Genesis 26:5). Rav Shimi bar Ḥiyya said to Rav: And say that the verse means that he fulfilled only the seven Noahide mitzvot and not the entire Torah. The Gemara asks: But isn’t there also circumcision that Abraham clearly observed, which is not one of the Noahide laws? Apparently, Abraham fulfilled more than just those seven. The Gemara asks: And say that he fulfilled only the seven mitzvot and circumcision. Rav said to him: If so, why do I need the continuation of the verse, that Abraham kept: My mitzvot and myTorah? That is a clear indication that he fulfilled mitzvot beyond the seven Noahide mitzvot, and apparently fulfilled the entire Torah.
אמר (רב) ואיתימא רב אשי קיים אברהם אבינו אפילו עירובי תבשילין שנאמר תורותי אחת תורה שבכתב ואחת תורה שבעל פה
Rav said, and some say Rav Ashi said: Abraham our Patriarch fulfilled the entire Torah, even the mitzva of the joining of cooked foods, a rabbinic ordinance instituted later, as it is stated: MyTorahs. Since the term is in the plural, it indicates that Abraham kept two Torahs; one, the Written Torah, and one, the Oral Torah. In the course of fulfilling the Oral Torah, he fulfilled all the details and parameters included therein.