{"thread":{"id":"17809","subject":"[PATCH 0/8] Support coverage testing with GCC/gcov","startedAt":"2009-02-15T22:25:37Z","lastAt":"2009-02-16T11:09:28Z","messageCount":11,"participants":["Thomas Rast","Matthieu Moy"],"isPatch":true,"patchVersion":1,"patchTotal":8},"messages":[{"id":"104834","messageId":"cover.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":null,"subject":"[PATCH 0/8] Support coverage testing with GCC/gcov","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:37Z","receivedAt":"2009-02-15T22:25:37Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"So I found a new toy to play with ;-)\n\nThe first patch adds some Makefile rules to automate coverage testing.\nThis initially resulted in a list of 497 untested functions.  Then I\npicked out some easy targets and made patches for them.  This shortens\nthe list by 20.\n\nNote that the rules currently don't consider any of the\nsubdirectories.  I'm not sure if arm, ppc, and compat are worth\nconsidering, but it would at least have been nice to support it for\nxdiff.  Unfortunately I can't convince the --coverage code to save\nresults there, so no analysis is possible.  (Running gcc 4.3.2 here.)\n\nBTW, I find it a bit scary that fsck (see 5/8) has so few tests, and\neven scarier that out of four simple tests I could come up with it\nonly passes two.  Let's hope the other two are unreasonable.\n\n\nThomas Rast (8):\n  Support coverage testing with GCC/gcov\n  Test that diff can read from stdin\n  Test diff --dirstat functionality\n  Test log --graph\n  Test fsck a bit harder\n  Test log --decorate\n  Test rev-list --parents/--children\n  Test git-patch-id\n\n Makefile                                      |   23 ++++\n t/t1450-fsck.sh                               |   65 +++++++++++\n t/t4002-diff-basic.sh                         |    8 ++\n t/t4013-diff-various.sh                       |    5 +\n t/t4013/diff.diff_--dirstat_master~1_master~2 |    3 +\n t/t4013/diff.log_--decorate_--all             |   34 ++++++\n t/t4013/diff.rev-list_--children_HEAD         |    7 +\n t/t4013/diff.rev-list_--parents_HEAD          |    7 +\n t/t4202-log.sh                                |  148 +++++++++++++++++++++++++\n t/t4203-patch-id.sh                           |   38 +++++++\n 10 files changed, 338 insertions(+), 0 deletions(-)\n create mode 100644 t/t4013/diff.diff_--dirstat_master~1_master~2\n create mode 100644 t/t4013/diff.log_--decorate_--all\n create mode 100644 t/t4013/diff.rev-list_--children_HEAD\n create mode 100644 t/t4013/diff.rev-list_--parents_HEAD\n create mode 100755 t/t4203-patch-id.sh\n"},{"id":"104836","messageId":"fb1e427bf56f5061634bc57fe6837f75e36c6cb2.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 1/8] Support coverage testing with GCC/gcov","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:38Z","receivedAt":"2009-02-15T22:25:38Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"With gcc's --coverage option, we can perform automatic coverage data\ncollection for the test suite.\n\nAdd a new Makefile target 'coverage' that scraps all previous coverage\nresults, recompiles git with the required compiler/linker flags (in\naddition to any flags you specify manually), then runs the test suite\nand compiles a report.\n\nThe compilation must be done with all optimizations disabled, since\ninlined functions (and for line-by-line coverage, also optimized\nbranches/loops) break coverage tracking.\n\nThe tests are run serially (with -j1).  The coverage code should\ntheoretically allow concurrent access to its data files, but the\nauthor saw random test failures.  Obviously this could be improved.\n\nThe report currently consists of a list of functions that were never\nexecuted during the tests, which is written to\n'coverage-untested-functions'.  Once this list becomes reasonably\nshort, we would also want to look at branches that were never taken.\n\nCurrently only toplevel *.c files are considered.  It would be nice to\nat least include xdiff, but --coverage did not save data to\nsubdirectories on the system used to write this (gcc 4.3.2).\n\nSigned-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n Makefile |   23 +++++++++++++++++++++++\n 1 files changed, 23 insertions(+), 0 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex b040a96..1c514a9 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -1640,3 +1640,26 @@ check-docs::\n check-builtins::\n \t./check-builtins.sh\n \n+### Test suite coverage testing\n+#\n+.PHONY: coverage coverage-clean coverage-build coverage-report\n+\n+coverage:\n+\t$(MAKE) coverage-build\n+\t$(MAKE) coverage-report\n+\n+coverage-clean:\n+\trm -f *.gcda *.gcno\n+\n+COVERAGE_CFLAGS = $(CFLAGS) -O0 -ftest-coverage -fprofile-arcs\n+COVERAGE_LDFLAGS = $(CFLAGS)  -O0 -lgcov\n+\n+coverage-build: coverage-clean\n+\t$(MAKE) CFLAGS=\"$(COVERAGE_CFLAGS)\" LDFLAGS=\"$(COVERAGE_LDFLAGS)\" \\\n+\t\t-j1 all test\n+\n+coverage-report:\n+\tgcov -b *.c\n+\tgrep '^function.*called 0 ' *.c.gcov \\\n+\t\t| sed -e 's/\\([^:]*\\)\\.gcov: *function \\([^ ]*\\) called.*/\\1: \\2/' \\\n+\t\t| tee coverage-untested-functions\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104838","messageId":"f5c76146f2c038dcc4f05f0e825b802f5b55fb1a.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 2/8] Test that diff can read from stdin","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:39Z","receivedAt":"2009-02-15T22:25:39Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Signed-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n\nNot the best possible place to put this, but t4013-diff-various.sh\ndoesn't let me do input redirections in its framework.\n\n t/t4002-diff-basic.sh |    8 ++++++++\n 1 files changed, 8 insertions(+), 0 deletions(-)\n\ndiff --git a/t/t4002-diff-basic.sh b/t/t4002-diff-basic.sh\nindex cc3681f..18695ce 100755\n--- a/t/t4002-diff-basic.sh\n+++ b/t/t4002-diff-basic.sh\n@@ -258,4 +258,12 @@ test_expect_success \\\n     git diff-tree -r -R $tree_A $tree_B >.test-b &&\n     cmp -s .test-a .test-b'\n \n+test_expect_success \\\n+    'diff can read from stdin' \\\n+    'test_must_fail git diff --no-index -- MN - < NN |\n+        grep -v \"^index\" | sed \"s#/-#/NN#\" >.test-a &&\n+    test_must_fail git diff --no-index -- MN NN |\n+        grep -v \"^index\" >.test-b &&\n+    test_cmp .test-a .test-b'\n+\n test_done\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104839","messageId":"74dedc1dea8500339a1c7bdc27a85a720ef3a663.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 3/8] Test diff --dirstat functionality","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:40Z","receivedAt":"2009-02-15T22:25:40Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"This is only a very rudimentary test, but it was untested before.\n\nSigned-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n t/t4013-diff-various.sh                       |    1 +\n t/t4013/diff.diff_--dirstat_master~1_master~2 |    3 +++\n 2 files changed, 4 insertions(+), 0 deletions(-)\n create mode 100644 t/t4013/diff.diff_--dirstat_master~1_master~2\n\ndiff --git a/t/t4013-diff-various.sh b/t/t4013-diff-various.sh\nindex aba5320..f140b9c 100755\n--- a/t/t4013-diff-various.sh\n+++ b/t/t4013-diff-various.sh\n@@ -263,6 +263,7 @@ diff --name-status dir2 dir\n diff --no-index --name-status dir2 dir\n diff --no-index --name-status -- dir2 dir\n diff master master^ side\n+diff --dirstat master~1 master~2\n EOF\n \n test_done\ndiff --git a/t/t4013/diff.diff_--dirstat_master~1_master~2 b/t/t4013/diff.diff_--dirstat_master~1_master~2\nnew file mode 100644\nindex 0000000..b672e1c\n--- /dev/null\n+++ b/t/t4013/diff.diff_--dirstat_master~1_master~2\n@@ -0,0 +1,3 @@\n+$ git diff --dirstat master~1 master~2\n+  40.0% dir/\n+$\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104840","messageId":"708e8ea6f799b25674cd1b1c6f9f3084b3156dd0.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 4/8] Test log --graph","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:41Z","receivedAt":"2009-02-15T22:25:41Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"So far there were no tests checking that log --graph actually works.\n\nNote that the tests strip trailing whitespace, as the current --graph\nemits trailing whitespace on lines that do not contain anything but\ngraph lines.\n\nSigned-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n t/t4202-log.sh |  148 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++\n 1 files changed, 148 insertions(+), 0 deletions(-)\n\ndiff --git a/t/t4202-log.sh b/t/t4202-log.sh\nindex 7b976ee..93966f7 100755\n--- a/t/t4202-log.sh\n+++ b/t/t4202-log.sh\n@@ -134,5 +134,153 @@ test_expect_success 'log --grep -i' '\n \ttest_cmp expect actual\n '\n \n+cat > expect <<EOF\n+* Second\n+* sixth\n+* fifth\n+* fourth\n+* third\n+* second\n+* initial\n+EOF\n+\n+test_expect_success 'simple log --graph' '\n+\tgit log --graph --pretty=tformat:%s >actual &&\n+\ttest_cmp expect actual\n+'\n+\n+test_expect_success 'set up merge history' '\n+\tgit checkout -b side HEAD~4 &&\n+\ttest_commit side-1 1 1 &&\n+\ttest_commit side-2 2 2 &&\n+\tgit checkout master &&\n+\tgit merge side\n+'\n+\n+cat > expect <<\\EOF\n+*   Merge branch 'side'\n+|\\\n+| * side-2\n+| * side-1\n+* | Second\n+* | sixth\n+* | fifth\n+* | fourth\n+|/\n+* third\n+* second\n+* initial\n+EOF\n+\n+test_expect_success 'log --graph with merge' '\n+\tgit log --graph --date-order --pretty=tformat:%s |\n+\t\tsed \"s/ *$//\" >actual &&\n+\ttest_cmp expect actual\n+'\n+\n+cat > expect <<\\EOF\n+*   commit master\n+|\\  Merge: A B\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     Merge branch 'side'\n+| |\n+| * commit side\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     side-2\n+| |\n+| * commit tags/side-1\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     side-1\n+| |\n+* | commit master~1\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     Second\n+| |\n+* | commit master~2\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     sixth\n+| |\n+* | commit master~3\n+| | Author: A U Thor <author@example.com>\n+| |\n+| |     fifth\n+| |\n+* | commit master~4\n+|/  Author: A U Thor <author@example.com>\n+|\n+|       fourth\n+|\n+* commit tags/side-1~1\n+| Author: A U Thor <author@example.com>\n+|\n+|     third\n+|\n+* commit tags/side-1~2\n+| Author: A U Thor <author@example.com>\n+|\n+|     second\n+|\n+* commit tags/side-1~3\n+  Author: A U Thor <author@example.com>\n+\n+      initial\n+EOF\n+\n+test_expect_success 'log --graph with full output' '\n+\tgit log --graph --date-order --pretty=short |\n+\t\tgit name-rev --name-only --stdin |\n+\t\tsed \"s/Merge:.*/Merge: A B/;s/ *$//\" >actual &&\n+\ttest_cmp expect actual\n+'\n+\n+test_expect_success 'set up more tangled history' '\n+\tgit checkout -b tangle HEAD~6 &&\n+\ttest_commit tangle-a tangle-a a &&\n+\tgit merge master~3 &&\n+\tgit merge side~1 &&\n+\tgit checkout master &&\n+\tgit merge tangle\n+'\n+\n+cat > expect <<\\EOF\n+*   Merge branch 'tangle'\n+|\\\n+| *   Merge branch 'side' (early part) into tangle\n+| |\\\n+| * \\   Merge branch 'master' (early part) into tangle\n+| |\\ \\\n+| * | | tangle-a\n+* | | |   Merge branch 'side'\n+|\\ \\ \\ \\\n+| * | | | side-2\n+| | | |/\n+| | |/|\n+| |/| |\n+| * | | side-1\n+* | | | Second\n+* | | | sixth\n+| | |/\n+| |/|\n+|/| |\n+* | | fifth\n+* | | fourth\n+|/ /\n+* | third\n+|/\n+* second\n+* initial\n+EOF\n+\n+test_expect_success 'log --graph with merge' '\n+\tgit log --graph --date-order --pretty=tformat:%s |\n+\t\tsed \"s/ *$//\" >actual &&\n+\ttest_cmp expect actual\n+'\n+\n test_done\n \n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104841","messageId":"fc8b0b6a528906e5d66eee3985b00bc3542cec54.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 5/8] Test fsck a bit harder","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:42Z","receivedAt":"2009-02-15T22:25:42Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"git-fsck, of all tools, has very few tests.  This adds some more:\n* a corrupted object;\n* a branch pointing to a non-commit;\n* a tag pointing to a nonexistent object;\n* and a tag pointing to an object of a type other than what the tag\n  itself claims.\n\nOnly the first two are caught.  At least the third probably should,\ntoo, but currently slips through.\n\nSigned-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n t/t1450-fsck.sh |   65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++\n 1 files changed, 65 insertions(+), 0 deletions(-)\n\ndiff --git a/t/t1450-fsck.sh b/t/t1450-fsck.sh\nindex 4597af0..302c910 100755\n--- a/t/t1450-fsck.sh\n+++ b/t/t1450-fsck.sh\n@@ -28,4 +28,69 @@ test_expect_success 'loose objects borrowed from alternate are not missing' '\n \t)\n '\n \n+# Corruption tests follow.  Make sure to remove all traces of the\n+# specific corruption you test afterwards, lest a later test trip over\n+# it.\n+\n+test_expect_success 'object with bad sha1' '\n+\tsha=$(echo blob | git hash-object -w --stdin) &&\n+\techo $sha &&\n+\told=$(echo $sha | sed \"s+^..+&/+\") &&\n+\tnew=$(dirname $old)/ffffffffffffffffffffffffffffffffffffff &&\n+\tsha=\"$(dirname $new)$(basename $new)\"\n+\tmv .git/objects/$old .git/objects/$new &&\n+\tgit update-index --add --cacheinfo 100644 $sha foo &&\n+\ttree=$(git write-tree) &&\n+\tcmt=$(echo bogus | git commit-tree $tree) &&\n+\tgit update-ref refs/heads/bogus $cmt &&\n+\t(git fsck 2>out; true) &&\n+\tgrep \"$sha.*corrupt\" out &&\n+\trm -f .git/objects/$new &&\n+\tgit update-ref -d refs/heads/bogus &&\n+\tgit read-tree -u --reset HEAD\n+'\n+\n+test_expect_success 'branch pointing to non-commit' '\n+\tgit rev-parse HEAD^{tree} > .git/refs/heads/invalid &&\n+\tgit fsck 2>out &&\n+\tgrep \"not a commit\" out &&\n+\tgit update-ref -d refs/heads/invalid\n+'\n+\n+cat > invalid-tag <<EOF\n+object ffffffffffffffffffffffffffffffffffffffff\n+type commit\n+tag invalid\n+tagger T A Gger <tagger@example.com> 1234567890 -0000\n+\n+This is an invalid tag.\n+EOF\n+\n+test_expect_failure 'tag pointing to nonexistent' '\n+\ttag=$(git hash-object -w --stdin < invalid-tag) &&\n+\techo $tag > .git/refs/tags/invalid &&\n+\tgit fsck --tags 2>out &&\n+\tgrep \"could not load tagged object\" out &&\n+\trm .git/refs/tags/invalid\n+'\n+\n+cat > wrong-tag <<EOF\n+object $(echo blob | git hash-object -w)\n+type commit\n+tag wrong\n+tagger T A Gger <tagger@example.com> 1234567890 -0000\n+\n+This is an invalid tag.\n+EOF\n+\n+test_expect_failure 'tag pointing to something else than its type' '\n+\ttag=$(git hash-object -w --stdin < wrong-tag) &&\n+\techo $tag > .git/refs/tags/wrong &&\n+\tgit fsck --tags 2>out &&\n+\tgrep \"some sane error message\" out &&\n+\trm .git/refs/tags/wrong\n+'\n+\n+\n+\n test_done\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104837","messageId":"e0a4935d798daf025ff884e8ad89bcc986c743fb.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 6/8] Test log --decorate","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:43Z","receivedAt":"2009-02-15T22:25:43Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Signed-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n t/t4013-diff-various.sh           |    1 +\n t/t4013/diff.log_--decorate_--all |   34 ++++++++++++++++++++++++++++++++++\n 2 files changed, 35 insertions(+), 0 deletions(-)\n create mode 100644 t/t4013/diff.log_--decorate_--all\n\ndiff --git a/t/t4013-diff-various.sh b/t/t4013-diff-various.sh\nindex f140b9c..e5715f3 100755\n--- a/t/t4013-diff-various.sh\n+++ b/t/t4013-diff-various.sh\n@@ -203,6 +203,7 @@ log --root -c --patch-with-stat --summary master\n log --root --cc --patch-with-stat --summary master\n log -SF master\n log -SF -p master\n+log --decorate --all\n \n whatchanged master\n whatchanged -p master\ndiff --git a/t/t4013/diff.log_--decorate_--all b/t/t4013/diff.log_--decorate_--all\nnew file mode 100644\nindex 0000000..12da8ac\n--- /dev/null\n+++ b/t/t4013/diff.log_--decorate_--all\n@@ -0,0 +1,34 @@\n+$ git log --decorate --all\n+commit 59d314ad6f356dd08601a4cd5e530381da3e3c64 (refs/heads/master)\n+Merge: 9a6d494 c7a2ab9\n+Author: A U Thor <author@example.com>\n+Date:   Mon Jun 26 00:04:00 2006 +0000\n+\n+    Merge branch 'side'\n+\n+commit c7a2ab9e8eac7b117442a607d5a9b3950ae34d5a (refs/heads/side)\n+Author: A U Thor <author@example.com>\n+Date:   Mon Jun 26 00:03:00 2006 +0000\n+\n+    Side\n+\n+commit 9a6d4949b6b76956d9d5e26f2791ec2ceff5fdc0\n+Author: A U Thor <author@example.com>\n+Date:   Mon Jun 26 00:02:00 2006 +0000\n+\n+    Third\n+\n+commit 1bde4ae5f36c8d9abe3a0fce0c6aab3c4a12fe44\n+Author: A U Thor <author@example.com>\n+Date:   Mon Jun 26 00:01:00 2006 +0000\n+\n+    Second\n+    \n+    This is the second commit.\n+\n+commit 444ac553ac7612cc88969031b02b3767fb8a353a (refs/heads/initial)\n+Author: A U Thor <author@example.com>\n+Date:   Mon Jun 26 00:00:00 2006 +0000\n+\n+    Initial\n+$\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104835","messageId":"e10e841375043b44bb5ca37773a60e80c849046e.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 7/8] Test rev-list --parents/--children","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:44Z","receivedAt":"2009-02-15T22:25:44Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Signed-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n\nrev-list doesn't really belong in diff-various, but it can be done\nvery easily in the existing framework, and there are log tests too...\n\n\n t/t4013-diff-various.sh               |    3 +++\n t/t4013/diff.rev-list_--children_HEAD |    7 +++++++\n t/t4013/diff.rev-list_--parents_HEAD  |    7 +++++++\n 3 files changed, 17 insertions(+), 0 deletions(-)\n create mode 100644 t/t4013/diff.rev-list_--children_HEAD\n create mode 100644 t/t4013/diff.rev-list_--parents_HEAD\n\ndiff --git a/t/t4013-diff-various.sh b/t/t4013-diff-various.sh\nindex e5715f3..0f359ca 100755\n--- a/t/t4013-diff-various.sh\n+++ b/t/t4013-diff-various.sh\n@@ -205,6 +205,9 @@ log -SF master\n log -SF -p master\n log --decorate --all\n \n+rev-list --parents HEAD\n+rev-list --children HEAD\n+\n whatchanged master\n whatchanged -p master\n whatchanged --root master\ndiff --git a/t/t4013/diff.rev-list_--children_HEAD b/t/t4013/diff.rev-list_--children_HEAD\nnew file mode 100644\nindex 0000000..e7f17d5\n--- /dev/null\n+++ b/t/t4013/diff.rev-list_--children_HEAD\n@@ -0,0 +1,7 @@\n+$ git rev-list --children HEAD\n+59d314ad6f356dd08601a4cd5e530381da3e3c64\n+c7a2ab9e8eac7b117442a607d5a9b3950ae34d5a 59d314ad6f356dd08601a4cd5e530381da3e3c64\n+9a6d4949b6b76956d9d5e26f2791ec2ceff5fdc0 59d314ad6f356dd08601a4cd5e530381da3e3c64\n+1bde4ae5f36c8d9abe3a0fce0c6aab3c4a12fe44 9a6d4949b6b76956d9d5e26f2791ec2ceff5fdc0\n+444ac553ac7612cc88969031b02b3767fb8a353a 1bde4ae5f36c8d9abe3a0fce0c6aab3c4a12fe44 c7a2ab9e8eac7b117442a607d5a9b3950ae34d5a\n+$\ndiff --git a/t/t4013/diff.rev-list_--parents_HEAD b/t/t4013/diff.rev-list_--parents_HEAD\nnew file mode 100644\nindex 0000000..65d2a80\n--- /dev/null\n+++ b/t/t4013/diff.rev-list_--parents_HEAD\n@@ -0,0 +1,7 @@\n+$ git rev-list --parents HEAD\n+59d314ad6f356dd08601a4cd5e530381da3e3c64 9a6d4949b6b76956d9d5e26f2791ec2ceff5fdc0 c7a2ab9e8eac7b117442a607d5a9b3950ae34d5a\n+c7a2ab9e8eac7b117442a607d5a9b3950ae34d5a 444ac553ac7612cc88969031b02b3767fb8a353a\n+9a6d4949b6b76956d9d5e26f2791ec2ceff5fdc0 1bde4ae5f36c8d9abe3a0fce0c6aab3c4a12fe44\n+1bde4ae5f36c8d9abe3a0fce0c6aab3c4a12fe44 444ac553ac7612cc88969031b02b3767fb8a353a\n+444ac553ac7612cc88969031b02b3767fb8a353a\n+$\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104842","messageId":"23dc30ed8d645391d6a1072f182a37d98bde460a.1234736374.git.trast@student.ethz.ch","threadId":"17809","inReplyTo":"cover.1234736374.git.trast@student.ethz.ch","subject":"[PATCH 8/8] Test git-patch-id","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-15T22:25:45Z","receivedAt":"2009-02-15T22:25:45Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"So far, git-patch-id was untested.  Add some simple checks for output\nformat and patch (in)equality.\n\nSigned-off-by: Thomas Rast <trast@student.ethz.ch>\n---\n t/t4203-patch-id.sh |   38 ++++++++++++++++++++++++++++++++++++++\n 1 files changed, 38 insertions(+), 0 deletions(-)\n create mode 100755 t/t4203-patch-id.sh\n\ndiff --git a/t/t4203-patch-id.sh b/t/t4203-patch-id.sh\nnew file mode 100755\nindex 0000000..04f7bae\n--- /dev/null\n+++ b/t/t4203-patch-id.sh\n@@ -0,0 +1,38 @@\n+#!/bin/sh\n+\n+test_description='git patch-id'\n+\n+. ./test-lib.sh\n+\n+test_expect_success 'setup' '\n+\ttest_commit initial foo a &&\n+\ttest_commit first foo b &&\n+\tgit checkout -b same HEAD^ &&\n+\ttest_commit same-msg foo b &&\n+\tgit checkout -b notsame HEAD^ &&\n+\ttest_commit notsame-msg foo c\n+'\n+\n+test_expect_success 'patch-id output is well-formed' '\n+\tgit log -p -1 | git patch-id > output &&\n+\tgrep \"^[a-f0-9]\\{40\\} $(git rev-parse HEAD)$\" output\n+'\n+\n+get_patch_id () {\n+\tgit log -p -1 \"$1\" | git patch-id |\n+\t\tsed \"s# .*##\" > patch-id_\"$1\"\n+}\n+\n+test_expect_success 'patch-id detects equality' '\n+\tget_patch_id master &&\n+\tget_patch_id same &&\n+\ttest_cmp patch-id_master patch-id_same\n+'\n+\n+test_expect_success 'patch-id detects inequality' '\n+\tget_patch_id master &&\n+\tget_patch_id notsame &&\n+\t! test_cmp patch-id_master patch-id_notsame\n+'\n+\n+test_done\n-- \n1.6.2.rc0.335.g1a2b\n"},{"id":"104920","messageId":"vpq3aeeoh53.fsf@bauges.imag.fr","threadId":"17809","inReplyTo":"fb1e427bf56f5061634bc57fe6837f75e36c6cb2.1234736374.git.trast@student.ethz.ch","subject":"Re: [PATCH 1/8] Support coverage testing with GCC/gcov","fromName":"Matthieu Moy","fromEmail":"matthieu.moy@imag.fr","sentAt":"2009-02-16T09:39:04Z","receivedAt":"2009-02-16T09:39:04Z","isPatch":true,"sender":{"key":"git@matthieu-moy.fr","avatar":"https://avatars.githubusercontent.com/u/14709?v=4"},"body":"detail:\n\nThomas Rast <trast@student.ethz.ch> writes:\n\n> With gcc's --coverage option, we can perform automatic coverage data\n\nI don't think gcc has a --coverage ...\n\n> +COVERAGE_CFLAGS = $(CFLAGS) -O0 -ftest-coverage -fprofile-arcs\n> +COVERAGE_LDFLAGS = $(CFLAGS)  -O0 -lgcov\n\n... and this is not the one you are using anyway.\n\n(but great thing to use gcov! thanks)\n\n-- \nMatthieu\n"},{"id":"104933","messageId":"200902161209.34188.trast@student.ethz.ch","threadId":"17809","inReplyTo":"vpq3aeeoh53.fsf@bauges.imag.fr","subject":"Re: [PATCH 1/8] Support coverage testing with GCC/gcov","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2009-02-16T11:09:28Z","receivedAt":"2009-02-16T11:09:28Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Matthieu Moy wrote:\n> detail:\n> \n> Thomas Rast <trast@student.ethz.ch> writes:\n> \n> > With gcc's --coverage option, we can perform automatic coverage data\n> \n> I don't think gcc has a --coverage ...\n\nMine does:\n\n  --coverage\n    This option is used to compile and link code instrumented for\n    coverage analysis.  The option is a synonym for -fprofile-arcs\n    -ftest-coverage (when compiling) and -lgcov (when linking).  See\n    the documentation for those options for more details.\n\n> > +COVERAGE_CFLAGS = $(CFLAGS) -O0 -ftest-coverage -fprofile-arcs\n> > +COVERAGE_LDFLAGS = $(CFLAGS)  -O0 -lgcov\n> \n> ... and this is not the one you are using anyway.\n\nIndeed, I guess the log message is somewhat misleading.\n\n-- \nThomas Rast\ntrast@{inf,student}.ethz.ch\n"}]}