Thread (183 messages) 183 messages, 9 authors, 2022-06-11

Re: [PATCH v8 1/6] unpack-objects: low memory footprint for get_data() in dry_run mode

From: Han Xin <hidden>
Date: 2022-01-11 10:41:29

On Sat, Jan 8, 2022 at 8:28 PM René Scharfe [off-list ref] wrote:
 Am 08.01.22 um 09:54 schrieb Han Xin:
quoted
From: Han Xin <redacted>

+assert_no_loose () {
+     glob=dest.git/objects/?? &&
+     echo "$glob" >expect &&
+     eval "echo $glob" >actual &&
+     test_cmp expect actual
+}
+
+assert_no_pack () {
+     rmdir dest.git/objects/pack
I would expect a function whose name starts with "assert" to have no
side effects.  It doesn't matter here, because it's called only at the
very end, but that might change.  You can use test_dir_is_empty instead
of rmdir.
*nod*
I think it would be better to rename "assert_no_loose()" to "test_no_loose()".
I will remove "assert_no_pack()" and use "test_dir_is_empty()" instead.

Thanks
-Han Xin
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help