git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCHv2 4/4] git-p4: update locked test case

From
Junio C Hamano <gitster@pobox.com>
Date
Apr 3, 2015, 21:55 UTC
Message-ID
<xmqqk2xsg9lp.fsf@gitster.dls.corp.google.com>
In-Reply-To
<CAPig+cSsPZZ=kEQ9jwj-BKkO+gKFwZYVi-FrTvvTZpmatmokAQ@mail.gmail.com>
Eric Sunshine <sunshine@sunshineco.com> writes:
Show 6 quoted lines
> On Fri, Apr 3, 2015 at 2:53 PM, Luke Diamand <luke@diamand.org> wrote:
>> The add-new-file and copy-existing-file tests from
>> t9816-git-p4-locked.sh now pass. Update the test
>> case accordingly.
>
> This patch should be folded into patch 3/4, shouldn't it?

If the fix and tests were done by the same person, we strongly prefer to see the code fix and test expectation update in the same commit.

What Luke is doing here is to spread the credits/blame to two people. If I were playing Luke's role, I might have squashed them into a single commit, kept the authorship of the whole thing under Blair Holloway's name, and extend the log message by mentioning that I flipped the test expectations, but I'd say either is fine for this change.

Show 29 quoted lines
>> Signed-off-by: Luke Diamand <luke@diamand.org>
>> ---
>>  t/t9816-git-p4-locked.sh | 4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/t/t9816-git-p4-locked.sh b/t/t9816-git-p4-locked.sh
>> index 464f10b..d048bd3 100755
>> --- a/t/t9816-git-p4-locked.sh
>> +++ b/t/t9816-git-p4-locked.sh
>> @@ -35,7 +35,7 @@ test_expect_success 'edit with lock not taken' '
>>         )
>>  '
>>
>> -test_expect_failure 'add with lock not taken' '
>> +test_expect_success 'add with lock not taken' '
>>         test_when_finished cleanup_git &&
>>         git p4 clone --dest="$git" //depot &&
>>         (
>> @@ -107,7 +107,7 @@ test_expect_failure 'chmod with lock taken' '
>>         )
>>  '
>>
>> -test_expect_failure 'copy with lock taken' '
>> +test_expect_success 'copy with lock taken' '
>>         lock_in_another_client &&
>>         test_when_finished cleanup_git &&
>>         test_when_finished "cd \"$cli\" && p4 revert file2 && rm -f file2" &&
>> --
>> 2.3.0.rc1.30.g76afe74
Previous: Eric Sunshine
Message 8 of 8 in “[PATCHv2 0/4] git-p4: fix filetype detection on files opened exclusively”
  1. Luke DiamandApr 3, 2015
  2. 1/4 git-p4: fix small bug in locked test scriptsLuke Diamand, Apr 3, 2015
  3. Eric SunshineApr 3, 2015
  4. 2/4 git-p4: small fix for locked-file-move-testLuke Diamand, Apr 3, 2015
  5. 3/4 git-p4: fix filetype detection on files opened exclusivelyLuke Diamand, Apr 3, 2015
  6. 4/4 git-p4: update locked test caseLuke Diamand, Apr 3, 2015
  7. Eric SunshineApr 3, 2015
  8. Junio C HamanoApr 3, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.