py: Make bytes objs work with more str methods; add tests.