(testrepo: Repository)
| 200 | |
| 201 | |
| 202 | def test_patch_create_blob_blobs(testrepo: Repository) -> None: |
| 203 | old_blob = testrepo[testrepo.create_blob(BLOB_OLD_CONTENT)] |
| 204 | new_blob = testrepo[testrepo.create_blob(BLOB_NEW_CONTENT)] |
| 205 | assert isinstance(old_blob, Blob) |
| 206 | assert isinstance(new_blob, Blob) |
| 207 | |
| 208 | patch = pygit2.Patch.create_from( |
| 209 | old_blob, |
| 210 | new_blob, |
| 211 | old_as_path=BLOB_OLD_PATH, |
| 212 | new_as_path=BLOB_NEW_PATH, |
| 213 | ) |
| 214 | |
| 215 | assert patch.text == BLOB_PATCH |
| 216 | |
| 217 | |
| 218 | def test_patch_create_blob_buffer(testrepo: Repository) -> None: |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…