Preheat oven to 160 C / Gas 3. Prepare your teacup cases by lining them up on a baking sheet. These cases won’t fit into the holes of a cupcake/muffin tin because of the teacup handles. Alternatively you can line a muffin tin with paper cases.
Melt the chocolate and butter together in a bowl over some simmering water, stirring until it looks smooth. Then remove from the heat and leave to cool slightly.
When the chocolate/butter mixture has cooled, add the egg and sugar and beat with a wooden spoon until well combined.
Add the sifted flour and chopped walnuts and gently fold in until all combined.
Divide the mixture evenly between the teacup cases and bake on the middle shelf for 15 to 17 minutes.
When baked, remove from the oven and leave to cool completely before decorating.
To decorate, whip up a batch of chocolate ganache icing and use it to fill a piping bag fitted with a star nozzle (I used a 2D closed star nozzle).
Give each teacup cake a big swirl of chocolate ganache icing and top with a slice of chocolate bar, or some sprinkles.