summaryrefslogtreecommitdiff
path: root/t/t6120-describe.sh
AgeCommit message (Collapse)Author
2008-09-03tests: use "git xyzzy" form (t3600 - t6999)Nanako Shiraishi
Converts tests between t3600-t6300. Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-03Fix describe --tags --long so it does not segfaultShawn O. Pearce
If we match a lightweight (non-annotated tag) as the name to output and --long was requested we do not have a tag, nor do we have a tagged object to display. Instead we must use the object we were passed as input for the long format display. Reported-by: Mark Burton <markb@ordern.com> Backtraced-by: Mikael Magnusson <mikachu@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-06-04Merge branch 'maint'Junio C Hamano
* maint: describe: match pattern for lightweight tags too
2008-06-04describe: match pattern for lightweight tags tooMichael Dressel
The <pattern> given "git describe --match" was used only to filter tag objects, and not to filter lightweight tags. This fixes it. [jc: made the log to clarify this is a bugfix, not an enhancement, with additional test] Signed-off-by: Michael Dressel <MichaelTiloDressel@t-online.de> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-05-24tests: do not use implicit "git diff --no-index"Junio C Hamano
As a general principle, we should not use "git diff" to validate the results of what git command that is being tested has done. We would not know if we are testing the command in question, or locating a bug in the cute hack of "git diff --no-index". Rather use test_cmp for that purpose. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-04t6120 (describe): check --long properlyJunio C Hamano
Existing test checked --long only for exactly tagged commit. We should make sure it works sensibly for commits that are not tagged. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-04Add git-describe test for "verify annotated tag names on output"Shawn O. Pearce
Back in 212945d4 ("Teach git-describe to verify annotated tag names before output") I taught git-describe to output the name shown in the "tag" header of an annotated tag, rather than the name it is actually stored under in this repository's ref namespace. This test case verifies this is working correctly by renaming the ref for an annotated tag to a different name that what is recorded in the tag body, and verifying that tag is returned. We also verify there is a message shown on stderr to inform the user that the tag is possibly stored under the wrong name locally. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-04Test for packed tags in git-describe outputShawn O. Pearce
In c374b91c ("git-describe: use tags found in packed-refs correctly") Junio fixed an issue where git-describe did not parse a tag object it obtained from a packed-refs file, as the peel information was read in from packed-refs and not the tag object itself. This new test case verifies the fix listed above is functioning, and does not have a regression in the future. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-04Don't allow git-describe failures to go unnoticed in t6120Shawn O. Pearce
If git-describe fails we never execute the test_expect_success, so we never actually test for failure. This is horribly wrong. We need to always run the test case, but the test case is only supposed to succeed if the prior git-describe returned 0. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-02-26git-describe: --long shows the object name even for a tagged commitSanti Béjar
This is useful when you want to see parts of the commit object name in "describe" output, even when the commit in question happens to be a tagged version. Instead of just emitting the tag name, it will describe such a commit as v1.2-0-deadbeef (0th commit since tag v1.2 that points at object deadbeef....). Signed-off-by: Santi Béjar <sbejar@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-07-03Rewrite "git-frotz" to "git frotz"Junio C Hamano
This uses the remove-dashes target to replace "git-frotz" to "git frotz". Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-01-15Add describe test.Junio C Hamano
... with help from Shawn. Signed-off-by: Junio C Hamano <junkio@cox.net>