In a deep skillet, combine the pesto, heavy cream, white wine (or broth), and minced garlic. Heat gently over medium heat until the sauce starts to bubble lightly. This ensures all the flavors blend beautifully.
Add the uncooked gnocchi directly to the sauce. Cover and cook for about 5 minutes. The gnocchi releases starch, which helps thicken the sauce naturally.
Uncover the pan, stir the gnocchi, and continue cooking for another 2-3 minutes. Once the sauce is creamy and thick, fold in the freshly grated Parmesan. Season with salt and pepper and serve immediately.