In a large pot, heat the olive oil over medium heat. Add the diced onion and sauté for about 3-4 minutes until it becomes translucent.
Stir in the minced garlic and cook for another 30 seconds, until fragrant.
Add the cubed chicken breast to the pot and season with salt and pepper. Cook, stirring frequently, until the chicken is no longer pink and cooked through, about 5-7 minutes.
Pour in the chicken broth and bring the mixture to a boil. Once boiling, reduce the heat to a simmer.
Stir in the heavy cream and basil pesto, allowing the soup to thicken slightly, about 3-5 minutes.
Gently add the gnocchi to the pot and cook as per package instructions, usually around 2-3 minutes or until they float to the top.
Fold in the fresh spinach and let it wilt in the heat of the soup for about 2 minutes.
Taste the soup and adjust seasoning with more salt and pepper if necessary.
Notes
Serve in warm bowls, garnished with grated Parmesan cheese and fresh basil leaves.