equal
deleted
inserted
replaced
12 transaction, |
12 transaction, |
13 vfs, |
13 vfs, |
14 ) |
14 ) |
15 |
15 |
16 from mercurial.revlogutils import ( |
16 from mercurial.revlogutils import ( |
|
17 constants, |
17 deltas, |
18 deltas, |
18 flagutil, |
19 flagutil, |
19 ) |
20 ) |
20 |
21 |
21 # TESTTMP is optional. This makes it convenient to run without run-tests.py |
22 # TESTTMP is optional. This makes it convenient to run without run-tests.py |
79 |
80 |
80 |
81 |
81 def newrevlog(name=b'_testrevlog.i', recreate=False): |
82 def newrevlog(name=b'_testrevlog.i', recreate=False): |
82 if recreate: |
83 if recreate: |
83 tvfs.tryunlink(name) |
84 tvfs.tryunlink(name) |
84 rlog = revlog.revlog(tvfs, name) |
85 rlog = revlog.revlog( |
|
86 tvfs, target=(constants.KIND_OTHER, b'test'), indexfile=name |
|
87 ) |
85 return rlog |
88 return rlog |
86 |
89 |
87 |
90 |
88 def appendrev(rlog, text, tr, isext=False, isdelta=True): |
91 def appendrev(rlog, text, tr, isext=False, isdelta=True): |
89 """Append a revision. If isext is True, set the EXTSTORED flag so flag |
92 """Append a revision. If isext is True, set the EXTSTORED flag so flag |