Preheat oven to 400°F. In a frying pan, add oil, onion, and salt. Stir occasionally until onions are just lightly caramelized (about 25 minutes) as they will continue to cook when baked so just look for a light golden color.
Remove from pan and set aside in a small bowl.
Add butter, pears, and sugar to same pan and stir to combine. Once softened, remove from heat and add to bowl of onions.
Create your mini tarts from the puff pasty by using a cookie cutter or sharp knife. I used a 2 inch square cookie cutter. Brush with beaten egg. In the center, add a 1/2 tablespoon of goat cheese and top with onion/pear mixture.
Bake for 20-25 minutes or until puff pastry is lightly golden.