Re: [PATCH 1/3] notes remove: allow removing more than one

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michael J Gruber <git@xxxxxxxxxxxxxxxxxxxx> writes:

[jc: cull the part you did not comment on, thanks]

>> +test_expect_success 'removing more than one' '
>> +	before=$(git rev-parse --verify refs/notes/commits) &&
>> +	test_when_finished "git update-ref refs/notes/commits $before" &&
>> +	git notes remove HEAD^^ HEAD^^^ &&
>> +	git diff --name-only refs/notes/commits^ refs/notes/commits >actual &&
>> +	test 2 = $(wc -l <actual) &&
>> +	git ls-tree -r --name-only refs/notes/commits >actual &&
>> +	>empty &&
>> +	test_cmp empty actual
>> +'
>
> You're not really testing that this removes the correct notes. Actually,
> you're not even testing that this removes only 2 notes when there are
> more than 2, are you?

In the test vector, there are only two notes, and I am testing removal of
multiple.  What do you want me to do?  Test removing one and make sure the
other one survives ;-)? 

Patches on top of it is very welcome, but I wouldn't bother.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]