Preheat the oven to 350 degrees F.
In a pan that can go from stovetop to oven, heat the oil over medium heat.
Add the mushrooms and onions and sauté for 8-10 minutes or until they are browned and beginning to caramelize, stirring occasionally. Stir in the garlic and cook, stirring, for 30-60 seconds more or until you can smell the garlic but it is not turning brown.
Add the rice and stir until coated. Sprinkle with the salt, pepper, and thyme.
Carefully, pour in the broth, increase heat, and bring to a boil.
As soon as the mixture boils, remove from the heat, cover, and bake for 45 minutes or until the broth is absorbed.
Remove from the oven and allow to sit, covered, for 10 minutes before serving.