Preheat the oven to 425 degrees F. Lightly spray two 6-ounce ramekins with the cooking spray and dust with cocoa powder, tapping out any excess.
Melt the butter and chocolate in the top of a double boiler over simmering water, stirring occasionally, until smooth.
Using a hand mixer, beat the egg, egg yolk, granulated sugar and salt on high speed until it becomes light in color and texture, about 2 minutes. Turn the mixer to low speed and beat in the chocolate mixture just until combined. Sift the flour onto the mixture, then fold it in using a rubber spatula.
Divide the batter between the two prepared ramekins and place them on a baking sheet. Bake the cakes until the edges are slightly puffed and set and the centers are just barely set, about 12 minutes.
Remove the cakes from the oven and let rest for 1 minute. Run a paring knife around each ramekin, then invert each cake onto a plate. Top the cakes with raspberries and dust with confectioners’ sugar. Serve immediately.