Used a Python 3 compatible StringIO in test_utils
Fixed #4117: Apply id attribute to the outer <ul> of RadioSelect
Fix #4592: Make CheckboxSelectMultiple more like RadioSelect.

I refactored RadioSelect and CheckboxSelectMultiple to
make them inherit from a base class, allowing them to share
the behavior of being able to iterate over their subwidgets.

Thanks to Matt McClanahan for the initial patch and to
Claude Paroz for the review.