01 - Preheat oven to 400°F. Line a 9-inch tart pan with the pastry sheet, trimming any excess. Prick the base with a fork and chill in the refrigerator.
02 - Heat olive oil and butter in a large skillet over medium heat. Add sliced onions and cook, stirring frequently, until softened and golden, about 15 minutes.
03 - Add mushrooms to the skillet and cook until tender and all moisture evaporates, approximately 8 to 10 minutes.
04 - Stir in minced garlic and thyme, cooking for an additional minute. Season with salt and pepper to taste, then remove from heat and let cool slightly.
05 - In a mixing bowl, whisk together crème fraîche, eggs, and milk. Fold in half of the grated cheese and season lightly with salt and pepper.
06 - evenly spread the mushroom and onion mixture over the chilled pastry base. Pour the custard filling on top, then sprinkle with the remaining cheese.
07 - Bake for 30 to 35 minutes until custard is set and the top is golden brown.
08 - Allow tart to cool for 10 minutes, garnish with chopped parsley if desired. Slice and serve warm or at room temperature.