1.Cook pasta in plenty of salted, boiling water for 8 to 10 minutes or according to packet instructions until just tender to the bite. Rinse with cold water to cool, then drain well and place in a large bowl. Add pesto and toss well to coat.
2.Heat a frying pan, add a film of oil, then add sliced peppers to the pan. Stir-fry to cook and lightly brown, then remove cooked peppers to the bowl with the pasta. Season with salt and pepper and toss well.
3.Cook beans in salted, boiling water for 2 to 3 minutes then drain and plunge into ice-cold water to cool completely. Drain beans and add to pasta along with the ham and basil. Season with salt and pepper, toss well and serve.