Cook the spaghetti in a saucepan with salted water according to the instructions on the packet.
Pluck the basil leaves from the stems. Halve tomatoes. Peel the garlic.
Put 2 tablespoons of oil, 2 tablespoons of cream cheese, parmesan, spinach, garlic and basil in a blender and chop everything until a creamy mixture is formed. Season with a little salt and pepper.
Roast pine nuts in a pan without oil.
Put the pasta in a colander, drain briefly and then return to the saucepan. Stir in the pesto, pine nuts and tomatoes and serve immediately.