# # patch "ChangeLog" # from [862e1b7d72bf19c783099e991788acecbaa9e11e] # to [b5a55db7ee111c62add8c6c865e5fb1fd64d380d] # # patch "tests/t_annotate.at" # from [d216df41c2dc211585a5d317cc31263651e47fa6] # to [3dee31119dd3ce7327d6708e5d1dcc88a021d48e] # # patch "tests/t_annotate_add_collision.at" # from [bc6cec77fe817f77889b7dd79c1a8c68a4b46796] # to [60211c52edc81160a971196762f678d70dd94af5] # # patch "tests/t_annotate_branch_collision.at" # from [13b7163070c635e0031d6e8b8d18955b2e083618] # to [9109836cbf4011c18f3f9645894c2b72acd5690b] # # patch "tests/t_annotate_copy_all.at" # from [a8469eb56dee949ccd34ee480ee4fae8cbc73e17] # to [18142f64b79ab569a6717bf8743e3bfbd88722ba] # # patch "tests/t_annotate_lineage_dependent.at" # from [7adce4d02108a140150a8f31470f7ffb23fa0260] # to [43ba9ce786c6d70078e023be6ea97e86e9da3d69] # # patch "tests/t_annotate_split_line.at" # from [3a5433e99435a842491f00c9a22b6bd03ff57dfe] # to [5386b60f613a9e97f92a02cd9fd0b38d7c58d253] # # patch "testsuite.at" # from [033af1b25953c643786edb6e5c5a2c5b8499c09e] # to [ad2746994325f5386ea968832e9c328c17d600ab] # ======================================================================== --- ChangeLog 862e1b7d72bf19c783099e991788acecbaa9e11e +++ ChangeLog b5a55db7ee111c62add8c6c865e5fb1fd64d380d @@ -1,8 +1,9 @@ 2005-08-15 Patrick Mauritz * testsuite.at, tests/*.at: make testsuite less demanding: - QGREP() and QEGREP() provide a portable [e]grep -q - export FOO=bar -> FOO=bar; export FOO + - tail -n $x -> TAIL($x) with appropriate macro 2005-08-15 Patrick Mauritz ======================================================================== --- tests/t_annotate.at d216df41c2dc211585a5d317cc31263651e47fa6 +++ tests/t_annotate.at 3dee31119dd3ce7327d6708e5d1dcc88a021d48e @@ -53,9 +53,9 @@ AT_CHECK(MONOTONE annotate foo0, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REV1, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REV1, [0], [ignore], [ignore]) # @@ -63,8 +63,8 @@ # AT_CHECK(MONOTONE annotate unchanged, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) # # annotate bar0 should now be @@ -74,8 +74,8 @@ AT_CHECK(MONOTONE annotate bar0, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV2, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV3, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV2, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV3, [0], [ignore], [ignore]) # @@ -95,14 +95,14 @@ # AT_CHECK(MONOTONE annotate bar0, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV0, [0], [ignore], [ignore]) -AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REV1, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV0, [0], [ignore], [ignore]) +AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REV1, [0], [ignore], [ignore]) AT_CHECK(MONOTONE annotate foo0, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV2, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV3, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV2, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV3, [0], [ignore], [ignore]) # # Try add of file on one side of branch @@ -151,8 +151,8 @@ AT_CHECK(MONOTONE annotate forkfile, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REV8, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REV9, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REV8, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REV9, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REV8, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- tests/t_annotate_add_collision.at bc6cec77fe817f77889b7dd79c1a8c68a4b46796 +++ tests/t_annotate_add_collision.at 60211c52edc81160a971196762f678d70dd94af5 @@ -54,8 +54,8 @@ AT_CHECK(MONOTONE annotate foo, [], [stdout], [ignore]) #AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REVL, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REVR, [0], [ignore], [ignore]) -#AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REV1, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REVL, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REVR, [0], [ignore], [ignore]) +#AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REV1, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- tests/t_annotate_branch_collision.at 13b7163070c635e0031d6e8b8d18955b2e083618 +++ tests/t_annotate_branch_collision.at 9109836cbf4011c18f3f9645894c2b72acd5690b @@ -55,8 +55,8 @@ AT_CHECK(MONOTONE annotate foo, [], [stdout], [ignore]) #AT_CHECK(head -n 1 stdout | grep $REV1, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REVL, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REVR, [0], [ignore], [ignore]) -#AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REV1, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REVL, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REVR, [0], [ignore], [ignore]) +#AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REV1, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- tests/t_annotate_copy_all.at a8469eb56dee949ccd34ee480ee4fae8cbc73e17 +++ tests/t_annotate_copy_all.at 18142f64b79ab569a6717bf8743e3bfbd88722ba @@ -59,9 +59,9 @@ AT_CHECK(MONOTONE annotate foo, [], [stdout], [ignore]) AT_CHECK(head -n 1 stdout | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REVB, [0], [ignore], [ignore]) -AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REVB, [0], [ignore], [ignore]) -AT_CHECK(head -n 5 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REVB, [0], [ignore], [ignore]) +AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REVB, [0], [ignore], [ignore]) +AT_CHECK(head -n 5 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- tests/t_annotate_lineage_dependent.at 7adce4d02108a140150a8f31470f7ffb23fa0260 +++ tests/t_annotate_lineage_dependent.at 43ba9ce786c6d70078e023be6ea97e86e9da3d69 @@ -74,10 +74,10 @@ AT_CHECK(MONOTONE --debug annotate foo, [], [stdout], [stderr]) AT_CHECK(head -n 1 stdout | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REVB, [0], [ignore], [ignore]) -AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REVC, [0], [ignore], [ignore]) -AT_CHECK(head -n 5 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 6 stdout | tail -n 1 | grep $REVD, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REVB, [0], [ignore], [ignore]) +AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REVC, [0], [ignore], [ignore]) +AT_CHECK(head -n 5 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 6 stdout | TAIL(1) | grep $REVD, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- tests/t_annotate_split_line.at 3a5433e99435a842491f00c9a22b6bd03ff57dfe +++ tests/t_annotate_split_line.at 5386b60f613a9e97f92a02cd9fd0b38d7c58d253 @@ -68,10 +68,10 @@ AT_CHECK(MONOTONE --debug annotate foo, [], [stdout], [stderr]) AT_CHECK(head -n 1 stdout | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 2 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 3 stdout | tail -n 1 | grep $REVB, [0], [ignore], [ignore]) -AT_CHECK(head -n 4 stdout | tail -n 1 | grep $REVC, [0], [ignore], [ignore]) -AT_CHECK(head -n 5 stdout | tail -n 1 | grep $REVA, [0], [ignore], [ignore]) -AT_CHECK(head -n 6 stdout | tail -n 1 | grep $REVD, [0], [ignore], [ignore]) +AT_CHECK(head -n 2 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 3 stdout | TAIL(1) | grep $REVB, [0], [ignore], [ignore]) +AT_CHECK(head -n 4 stdout | TAIL(1) | grep $REVC, [0], [ignore], [ignore]) +AT_CHECK(head -n 5 stdout | TAIL(1) | grep $REVA, [0], [ignore], [ignore]) +AT_CHECK(head -n 6 stdout | TAIL(1) | grep $REVD, [0], [ignore], [ignore]) AT_CLEANUP ======================================================================== --- testsuite.at 033af1b25953c643786edb6e5c5a2c5b8499c09e +++ testsuite.at ad2746994325f5386ea968832e9c328c17d600ab @@ -420,6 +420,8 @@ # same for QEGREP and egrep -q m4_define([QGREP], [grep $1 >/dev/null]) m4_define([QEGREP], [egrep $1 >/dev/null]) +# run as TAIL(lines) +m4_define([TAIL], [(tail -n $1 2>/dev/null || tail -$1)]) # include all the sub-tests we're going to use