(testrepo: Repository)
| 93 | |
| 94 | |
| 95 | def test_patch_create_from_blobs(testrepo: Repository) -> None: |
| 96 | old_blob = testrepo[BLOB_OLD_SHA] |
| 97 | new_blob = testrepo[BLOB_NEW_SHA] |
| 98 | assert isinstance(old_blob, Blob) |
| 99 | assert isinstance(new_blob, Blob) |
| 100 | |
| 101 | patch = pygit2.Patch.create_from( |
| 102 | old_blob, |
| 103 | new_blob, |
| 104 | old_as_path=BLOB_OLD_PATH, |
| 105 | new_as_path=BLOB_NEW_PATH, |
| 106 | ) |
| 107 | |
| 108 | assert patch.text == BLOB_PATCH2 |
| 109 | |
| 110 | |
| 111 | def test_patch_create_from_blob_buffer(testrepo: Repository) -> None: |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…