Heat 1 tablespoon of oil in a large frying pan over a high heat. Sprinkle the beef with salt and pepper. Add the beef to the hot pan and cook until brown on all sides but still very rare in the center. This will take 8 minutes total. Transfer the beef to a plate and refrigerate until it is cold. Set the pan aside (do not wash the pan).
Place the mushrooms in a food processor and blend for 10 to 15 seconds or until all the mushrooms are very finely chopped. Heat the remaining 2 tablespoons of oil in the same frying pan over moderate-high heat.
Add the shallots and sauté for 1 minute or until the shallots are tender, scraping up any browned bits from the bottom of the pan. Add the finely chopped mushrooms and sauté 5 minutes. Sprinkle with salt and pepper. Reduce the heat to medium and cook for 15 minutes, stirring occasionally, or until the mushroom mixture is dry. Set the mushroom mixture aside to cool completely.
To assemble and bake the beef:
Preheat the oven to 400°F Line a heavy large baking sheet with parchment paper. On a lightly floured surface, roll out each pastry sheet into a 16x10-inch rectangle.
Brush 2 inches of one long side of one rectangle with some of the beaten egg. Place one long side of the second rectangle atop the egg-coated edge of the first rectangle, overlapping the edges by 2 inches. Press gently to seal.
Spread half of the mushroom mixture lengthwise over the center of the pastry. Place the beef on top of the mushroom mixture. Spread the remaining mushroom mixture over the top of the beef. Fold the pastry over the beef, overlapping the pastry on top of the beef.
Brush the pastry ends with some of the beaten egg, then fold the pastry ends over the sides and top of the beef. Turn the pastry-encased beef over and onto a heavy baking sheet so that it is seam side down. Brush some of the beaten egg over the pastry. Score the top of the pastry decoratively with the dull side of a knife.
Bake for 45 minutes or until the pastry is cooked through and a meat thermometer registers 130°F when inserted into the center of the beef for medium-rare doneness. The temperature of the beef will rise as it rests.
Let the beef rest for 20 minutes. Transfer the beef to a cutting board. Reserve the pan juices. Simmer the wine in a heavy based small saucepan over a high heat for 5 minutes or until reduced by half. Pour in the reserved juices from the beef. Simmer 1 minute. Season the sauce to taste with salt and pepper.
Meanwhile, to cook the green beans:
Boil the green beans in a large pot of boiling salted water for about 3-4 minutes or until they are crisp-tender. Drain. Melt the butter in a medium sauté pan over a medium heat. Add the beans and toss to coat. Season to taste with salt and pepper.
Cut the beef and pastry crosswise into thick slices. Transfer the slices to plates. Spoon some wine sauce over the beef and serve with the green beans.