def test_invalid(self, s): with pytest.raises(TypeError): _ = utils.to_unicode(s)
def test_to_unicode(): for obj in STRINGS: assert isinstance(utils.to_unicode(obj), str) for obj in NOT_STRINGS: with pytest.raises(TypeError): utils.to_unicode(obj)
def test_valid(self, s): assert isinstance(utils.to_unicode(s), str)
def test_repr(): assert utils.to_unicode(str(DATASET)).startswith("Dataset")