Preheat the oven to 200C/400F/Gas 6.
For the onion confit, melt the butter in a small ovenproof frying pan over a medium heat, add the onions and cook gently for five minutes until softened.
Add the honey and cook for two minutes.
Cut out a circle of the puff pastry, the same width as the frying pan. Place the pastry over the cooked onions and prick the pastry with a fork. Place into the oven to cook for 10 minutes.
For the pesto, place the basil leaves and pine nuts into a food processor and blend together. Gradually pour in the olive oil, until the pesto reaches a pouring consistency. Season well with salt and freshly ground black pepper.
Remove the tart from the oven and transfer onto a serving plate. Place the goats' cheese on top.
To serve, pour the pesto around the tart and serve immediately.