Exhaustive test of String#trim behavior (Closes #253)

This should close #253.