Preheat oven (electric cooker: 200 °C/circulating air: 175 °C/gas: see manufacturer). Wash and halve the tomatoes. Grate parmesan. Boil up cream and season with salt and pepper. Mix tomatoes, mozzarella and uncooked gnocchi.
Pour into a greased casserole dish. Pour cream over it, sprinkle with parmesan.
Bake in a hot oven for about 15 minutes. Wash the basil, sprinkle leaves over the casserole. Serve with Parma ham.