Put the chicken breast-side down on a chopping board, then using strong kitchen scissors or shears, cut down either side of the backbone. Turn the chicken so it’s breast-side up, then press down on the breastbone to flatten it.
Heat the oven to 220C/200C fan.
Rub the chicken all over with olive oil and season well. Heat a heavy, ovenproof frying pan large enough to fit the flattened chicken and add a little oil. Put the chicken in breast-side down and cook for 5 minutes, then add the garlic and rosemary to the pan.
Put another heavy pan on top of the chicken to weigh it down, (a brick wrapped in foil is perfect, otherwise use tin cans) then put everything in the oven.
Roast for 45 minutes, then take the chicken out to rest for 10 minutes. Put the pan with the roasting juices over a medium heat and stir in the beans until warmed through.
To make the green sauce, put all the ingredients in a small food processor and pulse briefly.
Carve the chicken and serve with the beans, sauce and crusty bread.