Peel, chop and boil the sweet potatoes until they are soft. Set aside to cool.
Heat the oven to 360°F (180°C) and prepare an 11x7-inches (28x18cm) baking tin lined with baking paper.
Place the cooled sweet potatoes, black beans, walnuts, sugar and chocolate into a food processor and blitz until smooth. Next add in the olive oil and blitz again.
Transfer the batter into the baking tin and bake for 50 minutes. Remove from the oven and allow to cool completely on a wire rack, before cutting into 12 squares. Store in an airtight container.