(testrepo: Repository)
| 46 | @utils.requires_network |
| 47 | @works_in_linux |
| 48 | def test_nonunicode_branchname(testrepo: Repository) -> None: |
| 49 | folderpath = 'temp_repo_nonutf' |
| 50 | if os.path.exists(folderpath): |
| 51 | shutil.rmtree(folderpath) |
| 52 | newrepo = pygit2.clone_repository( |
| 53 | path=folderpath, url='https://github.com/pygit2/test_branch_notutf.git' |
| 54 | ) |
| 55 | bstring = b'\xc3master' |
| 56 | assert bstring in [ |
| 57 | (ref.split('/')[-1]).encode('utf8', 'surrogateescape') |
| 58 | for ref in newrepo.listall_references() |
| 59 | ] # Remote branch among references: 'refs/remotes/origin/\udcc3master' |
nothing calls this directly
no test coverage detected
searching dependent graphs…