Preheat oven to 400 degrees F. Grease an 8 x 8 casserole dish.
In a large skillet heat the olive oil over medium low heat. Add the onion, red pepper and garlic, season well with salt and pepper, cook about 5 minutes, stirring often until onion is tender.
Add the broth, all the beans but 1/2 cup and the spinach, bring to a simmer and cook about 5 minutes until the spinach is wilted. Mash up the 1/2 cup beans with a fork and mix them in too.
Remove from heat, mix in the basil and 1/2 cup of the Parmesan.
Pour into the casserole pan and sprinkle the remaining Parmesan over top. Bake 20 minutes. Sprinkle the bacon over top and serve with additional Parmesan cheese.