equal
deleted
inserted
replaced
1019 self.assertEqual(f.read(node2), fulltext2) |
1019 self.assertEqual(f.read(node2), fulltext2) |
1020 |
1020 |
1021 def testcensored(self): |
1021 def testcensored(self): |
1022 f = self._makefilefn() |
1022 f = self._makefilefn() |
1023 |
1023 |
1024 stored1 = storageutil.packmeta({b'censored': b'tombstone',}, b'') |
1024 stored1 = storageutil.packmeta( |
|
1025 { |
|
1026 b'censored': b'tombstone', |
|
1027 }, |
|
1028 b'', |
|
1029 ) |
1025 |
1030 |
1026 with self._maketransactionfn() as tr: |
1031 with self._maketransactionfn() as tr: |
1027 node0 = f.add(b'foo', None, tr, 0, nullid, nullid) |
1032 node0 = f.add(b'foo', None, tr, 0, nullid, nullid) |
1028 |
1033 |
1029 # The node value doesn't matter since we can't verify it. |
1034 # The node value doesn't matter since we can't verify it. |
1048 # Like above, except we do the rawdata() request first to |
1053 # Like above, except we do the rawdata() request first to |
1049 # isolate revision caching behavior. |
1054 # isolate revision caching behavior. |
1050 |
1055 |
1051 f = self._makefilefn() |
1056 f = self._makefilefn() |
1052 |
1057 |
1053 stored1 = storageutil.packmeta({b'censored': b'tombstone',}, b'') |
1058 stored1 = storageutil.packmeta( |
|
1059 { |
|
1060 b'censored': b'tombstone', |
|
1061 }, |
|
1062 b'', |
|
1063 ) |
1054 |
1064 |
1055 with self._maketransactionfn() as tr: |
1065 with self._maketransactionfn() as tr: |
1056 node0 = f.add(b'foo', None, tr, 0, nullid, nullid) |
1066 node0 = f.add(b'foo', None, tr, 0, nullid, nullid) |
1057 |
1067 |
1058 # The node value doesn't matter since we can't verify it. |
1068 # The node value doesn't matter since we can't verify it. |
1230 |
1240 |
1231 def testdeltaagainstcensored(self): |
1241 def testdeltaagainstcensored(self): |
1232 # Attempt to apply a delta made against a censored revision. |
1242 # Attempt to apply a delta made against a censored revision. |
1233 f = self._makefilefn() |
1243 f = self._makefilefn() |
1234 |
1244 |
1235 stored1 = storageutil.packmeta({b'censored': b'tombstone',}, b'') |
1245 stored1 = storageutil.packmeta( |
|
1246 { |
|
1247 b'censored': b'tombstone', |
|
1248 }, |
|
1249 b'', |
|
1250 ) |
1236 |
1251 |
1237 with self._maketransactionfn() as tr: |
1252 with self._maketransactionfn() as tr: |
1238 node0 = f.add(b'foo\n' * 30, None, tr, 0, nullid, nullid) |
1253 node0 = f.add(b'foo\n' * 30, None, tr, 0, nullid, nullid) |
1239 |
1254 |
1240 # The node value doesn't matter since we can't verify it. |
1255 # The node value doesn't matter since we can't verify it. |