def test_fs_str(): assert fs_str( "some path component/Something") == "some path component/Something" assert isinstance(fs_str("whatever"), str)
def test_fs_str_with_bytes(): with raises(AssertionError): fs_str(b"whatever")
def test_fs_str_with_bytes(): with pytest.raises(TypeError, match=r"^fs_str\(\) argument must not be bytes$"): fs_str(b"whatever")