git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nguyen Thai Ngoc Duy <pclouds@gmail.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [RFC PATCH v2 1/4] Prevent diff machinery from examining  assume-unchanged entries on worktree
Date: Tue, 11 Aug 2009 08:34:11 +0700	[thread overview]
Message-ID: <fcaeb9bf0908101834n7cc7cfaakbf2d92fe8f32e9b1@mail.gmail.com> (raw)
In-Reply-To: <alpine.DEB.1.00.0908101800480.8324@intel-tinevez-2-302>

2009/8/10 Johannes Schindelin <Johannes.Schindelin@gmx.de>:
>> +test_expect_success 'setup' '
>> +     echo zero > zero &&
>> +     git add zero &&
>> +     git commit -m zero &&
>> +     echo one > one &&
>> +     echo two > two &&
>> +     git add one two &&
>> +     git commit -m onetwo &&
>> +     git update-index --assume-unchanged one &&
>> +     echo borked >> one &&
>> +     test "$(git ls-files -v one)" = "h one"
>> +'
>
> Maybe use test_commit, to make it more readable?

Thanks. I did not know that (or forgot already). Will use it.

>
>> +
>> +test_expect_success 'diff-index does not examine assume-unchanged entries' '
>> +     git diff-index HEAD^ -- one | grep -q 5626abf0f72e58d7a153368ba57db4c673c0e171
>> +'
>> +
>> +# TODO ced_uptodate()
>
> What is this about?

It tests "if (ce_uptodate(ce) || (ce->ce_flags & CE_VALID))" and I was
pretty sure it hit ce_uptodate() first, so the second expression was
not tested.
-- 
Duy

  reply	other threads:[~2009-08-11  1:34 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-10 15:19 [RFC PATCH v2 0/4] Sparse checkout Nguyễn Thái Ngọc Duy
2009-08-10 15:19 ` [RFC PATCH v2 1/4] Prevent diff machinery from examining assume-unchanged entries on worktree Nguyễn Thái Ngọc Duy
2009-08-10 15:19   ` [RFC PATCH v2 2/4] gitignore: read from index if .gitignore is assume-unchanged Nguyễn Thái Ngọc Duy
2009-08-10 15:19     ` [RFC PATCH v2 3/4] unpack_trees(): add support for sparse checkout Nguyễn Thái Ngọc Duy
2009-08-10 15:19       ` [RFC PATCH v2 4/4] read-tree: add --no-sparse to turn off sparse hook Nguyễn Thái Ngọc Duy
2009-08-10 16:46         ` Johannes Schindelin
2009-08-11  1:38           ` Nguyen Thai Ngoc Duy
2009-08-11  5:13             ` Junio C Hamano
2009-08-11  6:50               ` Johannes Schindelin
2009-08-11  7:08                 ` Nguyen Thai Ngoc Duy
2009-08-10 16:41       ` [RFC PATCH v2 3/4] unpack_trees(): add support for sparse checkout Johannes Schindelin
2009-08-11  1:47         ` Nguyen Thai Ngoc Duy
2009-08-11  7:02           ` Johannes Schindelin
2009-08-10 16:33     ` [RFC PATCH v2 2/4] gitignore: read from index if .gitignore is assume-unchanged Johannes Schindelin
2009-08-11  1:57       ` Nguyen Thai Ngoc Duy
2009-08-11  8:12         ` Johannes Schindelin
2009-08-10 16:20   ` [RFC PATCH v2 1/4] Prevent diff machinery from examining assume-unchanged entries on worktree Johannes Schindelin
2009-08-11  1:34     ` Nguyen Thai Ngoc Duy [this message]
2009-08-11  6:45       ` Johannes Schindelin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fcaeb9bf0908101834n7cc7cfaakbf2d92fe8f32e9b1@mail.gmail.com \
    --to=pclouds@gmail.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).