Test text to bytes auto-conversion
This commit is contained in:
parent
81ebb79e66
commit
a80f3af917
@ -215,6 +215,10 @@ class TestTypes(unittest.TestCase):
|
||||
assert obj.atext == six.u('somebytes')
|
||||
assert isinstance(obj.atext, types.text)
|
||||
|
||||
obj.abytes = six.u('sometext')
|
||||
assert obj.abytes == six.b('sometext')
|
||||
assert isinstance(obj.abytes, types.bytes)
|
||||
|
||||
def test_named_attribute(self):
|
||||
class AType(object):
|
||||
a_list = types.wsattr([int], name='a.list')
|
||||
|
Loading…
x
Reference in New Issue
Block a user