Rub the butter into the flour until it resembles breadcrumbs. This stage can be done in a food processor if you prefer. Add sufficient water to bind the pastry to form a ball of dough. Ideally, leave to rest for around 30 minutes before rolling out.
Roll out and line a 20cm diameter flan dish (ideally a non-stick loose bottomed flan dish).
To prepare the filling
Grate the cheese and place the grated cheese in the pastry case and place evenly over the pastry base with the spinach. If the spinach leaves are large you may wish to tear them first.
Slice the leeks and mushrooms and arrange evenly over the cheese.
Beat the eggs and milk together and pour into the pastry case.
To bake
Preheat the oven to 180oC, 350oF, gas mark 4.
Bake in the centre of the oven for around 30 to 40 minutes, or until the filling has risen, is firm and is golden. For an Aga, bake on the floor of the roasting oven for 10 minutes and then move to the centre of the oven until cooked.
Serve hot, or leave to cool on a wire cooling rack and then chill.