Buckets:

download
raw
401 Bytes
from autopr import parser
def test_parse_diff_basic():
diff = """
+++ b/src/foo.py
@@ -1,3 +1,6 @@
+def added(a, b):
+ return a + b
-def removed():
"""
out = parser.parse_diff(diff)
assert isinstance(out, dict)
assert "src/foo.py" in out["files_changed"]
assert out["added_lines"] >= 2
assert "added" in ",".join(out["added_functions"]) or "added" # quick contains check

Xet Storage Details

Size:
401 Bytes
·
Xet hash:
9b82032d7f6e12c2eeffa7cf2d2d97970b0001f95e70d722670e944d48a9a6e5

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.