From: "Øystein Walle" <oystwa@gmail•com>
To: git@vger•kernel.org
Subject: Re: [PATCH v3] stash: handle specifying stashes with spaces
Date: Wed, 8 Jan 2014 00:03:54 +0000 (UTC) [thread overview]
Message-ID: <loom.20140108T003945-67@post.gmane.org> (raw)
In-Reply-To: xmqqiotvbf4g.fsf@gitster.dls.corp.google.com
Junio C Hamano <gitster <at> pobox.com> writes:
>
> Thomas Rast <tr <at> thomasrast.ch> writes:
>
> > Junio C Hamano <gitster <at> pobox.com> writes:
> >
> >>
> >> This is brittle. If new tests are added before this, the test_tick
> >> will give you different timestamp and this test will start failing.
> >>
> >> Perhaps grab the timestamp out of the stash that was created [...]
> >
> > Hmm, now that I stare at this, why not simply use something like
> >
> > git stash apply "stash <at> { 0 }"
> >
> > It seems to refer to the same as stash <at> {0} as one would expect, while
> > still triggering the bug with unpatched git-stash.
>
> Yeah, that is fine as well. For the record, here is what I
> tentatively queued.
>
I completely agree that it's brittle. I mentioned it when I submitted v1
but at the time it didn't occur to me that new tests might be added
before it. And of course I agree with your proposed changes to the test.
I must say I like Thomas' solution because of its simplicity and the
whole test could be made much shorter: just create stash and try to pop
it.
But it's seems the spaces trigger some other way of interpreting the
selector. In my git.git, git rev-parse HEAD{0} gives me the same result
as HEAD@{ 0 } but HEAD@{1} and HEAD@{ 1 } are different. Is this
intentional? If not, can this impact the reliability of the test if we
use HEAD@{ 0 } ?
Thanks for queuing!
Regards,
Øsse
next prev parent reply other threads:[~2014-01-08 0:04 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-07 8:22 [PATCH v3] stash: handle specifying stashes with spaces Øystein Walle
2014-01-07 18:42 ` Junio C Hamano
2014-01-07 22:17 ` Thomas Rast
2014-01-07 22:29 ` Junio C Hamano
2014-01-08 0:03 ` Øystein Walle [this message]
2014-01-09 18:42 ` Junio C Hamano
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=loom.20140108T003945-67@post.gmane.org \
--to=oystwa@gmail$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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