#
# patch "ChangeLog"
# from [233887d0a5c095f89bf692f7ac4ae9eac11ee31f]
# to [862e1b7d72bf19c783099e991788acecbaa9e11e]
#
# patch "tests/t_ambig_update.at"
# from [759e9161edca5ede267c40573f95d088a1e9b3ab]
# to [5d0c04ee2f70686bd873ce3a40dca77cd8e545b9]
#
# patch "tests/t_ambiguous_tags.at"
# from [de01b6e6641e896d423ac223cbfdebfe8ccd5dfe]
# to [a4d848c1c5af6a888d0f5cb8798e73c476e03c4d]
#
# patch "tests/t_attr.at"
# from [b2c451cdd4b25730bba903849269d016da86241b]
# to [92a11a1c55e548100781ec72efa20c3f4385464e]
#
# patch "tests/t_attr_drop.at"
# from [6c25e3f9b2ed44bcafbc9c6881f457505c8b2e00]
# to [78473fb350f812e2f0bb9e6b6e65daaa889b0626]
#
# patch "tests/t_attr_init.at"
# from [2808c8a9f6fb506e726f6fd7c6daab46946cca50]
# to [5f88d7c651d2287951fe0181212da2a13331a9ad]
#
# patch "tests/t_automate_attributes.at"
# from [ed576e9065c0ed437f563975e7fb8fae967d233d]
# to [06fcfbc15fb0a02778f4ce7fb2c130923fe60262]
#
# patch "tests/t_automate_version.at"
# from [edfbab6a96e3d5ac6c41be5166f82cf5ce7a97df]
# to [0122d082b47e45e5bd47b7af4e0d5531d4f5f131]
#
# patch "tests/t_checkout_options.at"
# from [20a1f8dab6d0d4e5699e051003db72438423797a]
# to [284cbcd4e896cb06bbc46ff4f72339aab6905c8b]
#
# patch "tests/t_commit_log_1.at"
# from [7c5599e3f7447950849b3f22dfa8e2b2e2acaea2]
# to [7f484d7237acc02b49235fcbd05fee00fb3ff4e7]
#
# patch "tests/t_commit_log_2.at"
# from [444dccb6fe68c8c56974c997843ad9e986c3d553]
# to [367f752f3e6fe48cdb41a182b9428129d32de8ee]
#
# patch "tests/t_commit_message_file.at"
# from [a44df1257c0a0400d00f6876f1c82eb64b0466ac]
# to [aa49a6a98a40d510813800cd39cf9ae399bef4ed]
#
# patch "tests/t_cvsimport2.at"
# from [041a3f5713eec32152977b2dd410da42e7fa61b4]
# to [a149cb06fc8e5edc8ad655187e92c2082b050564]
#
# patch "tests/t_database_check_minor.at"
# from [eaba52f05e60be3f4bfc420af0722fd5ed63df02]
# to [c3716a80023cce652e10ebebb1df1e405a9d86ca]
#
# patch "tests/t_db_execute.at"
# from [992a2c0fe487f6ac987a168084e65c2c4636e91b]
# to [cad25454a737ae7296cf95712501b7320b4e3898]
#
# patch "tests/t_db_kill_branch_certs_locally.at"
# from [7821995222e42c3f8c89753df9168eebe27e0a8b]
# to [4b77eb010e0fad546869da1d6af69d0a1a81d36d]
#
# patch "tests/t_diff_external.at"
# from [d05dbe56b40eadaac3018fec89ffda8640f59f23]
# to [e4c70aa4c4144040ea0b027948f6a8dc98a55ae9]
#
# patch "tests/t_diff_first_rev.at"
# from [45914ceefd54646b62ee8e2cc68a92f2f7d1666d]
# to [6ae8976a600c70b0ddaba8ed4e399037685fe968]
#
# patch "tests/t_diff_restrict.at"
# from [12d098b7ad489c927d48c3e3be5a5ea5fb122213]
# to [ee27d0b0ec717a1ca9a88009ace00ecd56e75370]
#
# patch "tests/t_drop_attr.at"
# from [a88f420f9e89876865d487e8d16fa0d76a117c01]
# to [edb460d1adb623cf01b29f6945af549becb263d5]
#
# patch "tests/t_dropkey_1.at"
# from [b60d83a960145f795130597f4fc48b0f773429fa]
# to [87e5a23e7ed8df5db283b295648832ef72b0f5f7]
#
# patch "tests/t_dropkey_2.at"
# from [273fd69925b633a137a326975a2ba6a1d1f45293]
# to [52a101950139d3799bf23b1f789de3503d37741f]
#
# patch "tests/t_existsonpath.at"
# from [3bbd717c0872f45e088cd95b692a1fc0c649583f]
# to [fc7253fa711c37e25ffdd8e0aa90a631286926f5]
#
# patch "tests/t_heads.at"
# from [b5f1e0cc996bc9356d0bfd6189b3f7a7e9287a91]
# to [de84bc0854989c38fb5d424a87eef0f9964c4cab]
#
# patch "tests/t_heads_discontinuous_branch.at"
# from [8c830776ab70d8775298aac86e89f32f98922d3f]
# to [c76e752a9c3d9bff30e7a0eb511de7f50eab9f07]
#
# patch "tests/t_inodeprints.at"
# from [6fa42cdc469696e818f9df7569c9c0412117da42]
# to [d67a539bc4da605a1959d597bf5747557bc3548f]
#
# patch "tests/t_kill_tag_locally.at"
# from [b091837656ce01a0b6ecf80706725d3251e00abf]
# to [62be6ee4e44142ec69963f446c196ade4a71174c]
#
# patch "tests/t_lua_includedir.at"
# from [5b4ce1e6a2781a7a841039a1e02a96cc0221f3ff]
# to [06e756a957d1d330d347970c0c32def0936c7702]
#
# patch "tests/t_merge_lca.at"
# from [b3836fc9531f92a6fb429e97c0c3076dadc80aeb]
# to [b91ca296740e117ca8a8a2f86fad02764f126f07]
#
# patch "tests/t_migrate_schema.at"
# from [a5021d066df05e23620346dbc5cf480377af160f]
# to [2074b20ad00853b9490ce370b6e6002bf2fe52f2]
#
# patch "tests/t_multiple_heads_msg.at"
# from [e662d7470063759b847c0d98362dddb90ee7d0b6]
# to [e18276c0c4588a1bac33d4db0f84921eee8419a1]
#
# patch "tests/t_netsync_exclude.at"
# from [eea97484d1bd402e60fe263d96416c58cd09e96f]
# to [5a8302a38e8e62edb41b4332822cf82458177d85]
#
# patch "tests/t_netsync_pubkey.at"
# from [e4619acef738ea59b9ba6cc957bc20dd20a465cf]
# to [61ed3de939144d8bd75884dc842a4dfde299ac96]
#
# patch "tests/t_netsync_read_permissions.at"
# from [b25f34bb748f72ffa5cdfe08f91d982c2b87eaff]
# to [0550bdeac357f6794dd4849b2f0c0ba05a8c6286]
#
# patch "tests/t_no_change_deltas.at"
# from [41f660ced1f5900ec5a839e8920a8e4b3cd70fcd]
# to [3f44bcd2b864ef0d1294d6609d0880b61dfd4de7]
#
# patch "tests/t_normalized_filenames.at"
# from [5e0d909dd5f1dbd5502d327e94a108bcc60bec74]
# to [7b5a8ccabc5c0fea6a19cc901373c9336be7af59]
#
# patch "tests/t_override_author_date.at"
# from [e16cba63a1e9ce16356e6ae32fd95a89a13b79f2]
# to [28f11d05555f865105d40e0ec0b3454043082750]
#
# patch "tests/t_persistent_server_keys.at"
# from [9f7d8f9f1f3b0b8eb790534c8b14939d62595ccf]
# to [3b2ee5cc35e8e124a22a00d334a5c9bcfeac4101]
#
# patch "tests/t_persistent_server_keys_2.at"
# from [996841cb3e53d98bf67aa1a92c2d571235eed71e]
# to [f974ca0aba33b2107a1fd7677ded50faa52b3a05]
#
# patch "tests/t_propagate_desc.at"
# from [282d88d1143283a8cfcc14a12456d97d09349ea3]
# to [b03a137a514b121a1ba4ae31b63b86ee37f2cdb8]
#
# patch "tests/t_rcfile_dir.at"
# from [06128ab21f137c3a69e4fce2db25b0ea3fa424de]
# to [ef248856acc3362e65a272c54c8ce0131c3aae0f]
#
# patch "tests/t_rcfile_stdin.at"
# from [aea482a47a5493616df5dcf06972f174071b3f3a]
# to [09db80cb7bee886ced4c2cb8afbf1be24e04f699]
#
# patch "tests/t_rename_attr.at"
# from [73f6d07fd5c560ab99d9dd5c7bae3330dbdfb43c]
# to [d3a2ae2f643dcd6a58ebfff874bab269dfa71c4f]
#
# patch "tests/t_sql_unpack.at"
# from [981ed9637487312b00fc8db23ba9cc0e74003a85]
# to [1bb994c7c10fcfafc2a0fc9b5dd7c45b5b315174]
#
# patch "tests/t_trusted.at"
# from [7f4fd1fc5985d5c185eeed815c70a11c2683442b]
# to [2ba3de4eef581c8da540326f851df50232d744c2]
#
# patch "tests/t_update_branch.at"
# from [0ed6d5a93df9833bcf10e4144e5c6d7fa12a147b]
# to [b6390318109dc91675aa8a174de4a911cf9c8618]
#
# patch "testsuite.at"
# from [278a66fff09e8e04fef830272049d3e88d4f0fc1]
# to [033af1b25953c643786edb6e5c5a2c5b8499c09e]
#
========================================================================
--- ChangeLog 233887d0a5c095f89bf692f7ac4ae9eac11ee31f
+++ ChangeLog 862e1b7d72bf19c783099e991788acecbaa9e11e
@@ -1,5 +1,11 @@
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
+
+2005-08-15 Patrick Mauritz
+
* m4/typeof.m4: new test, looks if compiler knows the typeof()
extension
* configure.ac: use it
========================================================================
--- tests/t_ambig_update.at 759e9161edca5ede267c40573f95d088a1e9b3ab
+++ tests/t_ambig_update.at 5d0c04ee2f70686bd873ce3a40dca77cd8e545b9
@@ -28,9 +28,9 @@
AT_CHECK(MONOTONE update, [1], [ignore], [stderr])
AT_CHECK(test ! -e file1)
# Make sure that the failure message listed the possibilities
-AT_CHECK(grep -q $LEFT stderr, [])
-AT_CHECK(grep -q $RIGHT stderr, [])
-AT_CHECK(grep -q $ANC stderr, [1])
+AT_CHECK(QGREP($LEFT stderr), [])
+AT_CHECK(QGREP($RIGHT stderr), [])
+AT_CHECK(QGREP($ANC stderr), [1])
# Check also when one side is deeper than the other...
REVERT_TO($LEFT)
@@ -46,9 +46,9 @@
AT_CHECK(test ! -e file1)
AT_CHECK(test ! -e file2)
# Make sure that the failure message listed the possibilities
-AT_CHECK(grep -q $LEFT stderr, [1])
-AT_CHECK(grep -q $LEFT2 stderr, [])
-AT_CHECK(grep -q $RIGHT stderr, [])
-AT_CHECK(grep -q $ANC stderr, [1])
+AT_CHECK(QGREP($LEFT stderr), [1])
+AT_CHECK(QGREP($LEFT2 stderr), [])
+AT_CHECK(QGREP($RIGHT stderr), [])
+AT_CHECK(QGREP($ANC stderr), [1])
AT_CLEANUP
========================================================================
--- tests/t_ambiguous_tags.at de01b6e6641e896d423ac223cbfdebfe8ccd5dfe
+++ tests/t_ambiguous_tags.at a4d848c1c5af6a888d0f5cb8798e73c476e03c4d
@@ -15,7 +15,7 @@
AT_CHECK(MONOTONE tag $R2 ambig_tag, [], [ignore], [ignore])
AT_CHECK(MONOTONE ls tags, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1 stdout)
-AT_CHECK(grep -q $R2 stdout)
+AT_CHECK(QGREP($R1 stdout))
+AT_CHECK(QGREP($R2 stdout))
AT_CLEANUP
========================================================================
--- tests/t_attr.at b2c451cdd4b25730bba903849269d016da86241b
+++ tests/t_attr.at 92a11a1c55e548100781ec72efa20c3f4385464e
@@ -5,10 +5,10 @@
])
AT_CHECK(MONOTONE attr set testfile unique_key unique_value, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q unique_key stdout)
-AT_CHECK(grep -q unique_value stdout)
+AT_CHECK(QGREP(unique_key stdout))
+AT_CHECK(QGREP(unique_value stdout))
AT_CHECK(MONOTONE attr get testfile unique_key, [], [stdout], [ignore])
-AT_CHECK(grep -q unique_value stdout)
+AT_CHECK(QGREP(unique_value stdout))
COMMIT(testbranch)
REV=`BASE_REVISION`
========================================================================
--- tests/t_attr_drop.at 6c25e3f9b2ed44bcafbc9c6881f457505c8b2e00
+++ tests/t_attr_drop.at 78473fb350f812e2f0bb9e6b6e65daaa889b0626
@@ -6,21 +6,21 @@
AT_CHECK(MONOTONE attr set testfile first_key first_value, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr set testfile second_key second_value, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q first_key stdout)
-AT_CHECK(grep -q first_value stdout)
-AT_CHECK(grep -q second_key stdout)
-AT_CHECK(grep -q second_value stdout)
+AT_CHECK(QGREP(first_key stdout))
+AT_CHECK(QGREP(first_value stdout))
+AT_CHECK(QGREP(second_key stdout))
+AT_CHECK(QGREP(second_value stdout))
AT_CHECK(MONOTONE attr drop testfile first_key, [], [stdout], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q first_key stdout, [1])
-AT_CHECK(grep -q first_value stdout, [1])
-AT_CHECK(grep -q second_key stdout)
-AT_CHECK(grep -q second_value stdout)
+AT_CHECK(QGREP(first_key stdout), [1])
+AT_CHECK(QGREP(first_value stdout), [1])
+AT_CHECK(QGREP(second_key stdout))
+AT_CHECK(QGREP(second_value stdout))
AT_CHECK(MONOTONE attr drop testfile, [], [stdout], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q first_key stdout, [1])
-AT_CHECK(grep -q first_value stdout, [1])
-AT_CHECK(grep -q second_key stdout, [1])
-AT_CHECK(grep -q second_value stdout, [1])
+AT_CHECK(QGREP(first_key stdout), [1])
+AT_CHECK(QGREP(first_value stdout), [1])
+AT_CHECK(QGREP(second_key stdout), [1])
+AT_CHECK(QGREP(second_value stdout), [1])
AT_CLEANUP
========================================================================
--- tests/t_attr_init.at 2808c8a9f6fb506e726f6fd7c6daab46946cca50
+++ tests/t_attr_init.at 5f88d7c651d2287951fe0181212da2a13331a9ad
@@ -23,11 +23,11 @@
AT_CHECK(MONOTONE --rcfile=hook.lua add magic, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q test_attr stdout, [1])
-AT_CHECK(grep -q bob stdout, [1])
+AT_CHECK(QGREP(test_attr stdout), [1])
+AT_CHECK(QGREP(bob stdout), [1])
AT_CHECK(MONOTONE attr get magic, [], [stdout], [ignore])
-AT_CHECK(grep -q test_attr stdout, [])
-AT_CHECK(grep -q bob stdout, [])
+AT_CHECK(QGREP(test_attr stdout), [])
+AT_CHECK(QGREP(bob stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_automate_attributes.at ed576e9065c0ed437f563975e7fb8fae967d233d
+++ tests/t_automate_attributes.at 06fcfbc15fb0a02778f4ce7fb2c130923fe60262
@@ -5,8 +5,8 @@
])
AT_CHECK(MONOTONE attr set testfile unique_key unique_value, [], [ignore], [ignore])
AT_CHECK(MONOTONE automate attributes testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q unique_key stdout)
+AT_CHECK(QGREP(unique_key stdout))
AT_CHECK(MONOTONE automate attributes, [], [stdout], [ignore])
-AT_CHECK(grep -q testfile stdout)
+AT_CHECK(QGREP(testfile stdout))
AT_CLEANUP
========================================================================
--- tests/t_automate_version.at edfbab6a96e3d5ac6c41be5166f82cf5ce7a97df
+++ tests/t_automate_version.at 0122d082b47e45e5bd47b7af4e0d5531d4f5f131
@@ -7,6 +7,6 @@
# MinGW's wc produces " 1" as output. Arithmetic comparison works, string comparison doesn't
AT_CHECK(test 1 -eq "`wc -l @+\.@<:@0-9@:>@+$' a_v)
+AT_CHECK(QEGREP('^@<:@0-9@:>@+\.@<:@0-9@:>@+$' a_v))
AT_CLEANUP
========================================================================
--- tests/t_checkout_options.at 20a1f8dab6d0d4e5699e051003db72438423797a
+++ tests/t_checkout_options.at 284cbcd4e896cb06bbc46ff4f72339aab6905c8b
@@ -30,10 +30,10 @@
for DIR in test_dir{1,2,3,4,5,6,7,8}; do
AT_CHECK(echo DIR=$DIR, [], [ignore])
AT_CHECK(test -f $DIR/MT/options)
- AT_CHECK(grep -q test.db $DIR/MT/options)
- AT_CHECK(grep -q testbranch $DIR/MT/options)
+ AT_CHECK(QGREP(test.db $DIR/MT/options))
+ AT_CHECK(QGREP(testbranch $DIR/MT/options))
done
-AT_CHECK(grep -q foobar test_dir10/MT/options)
+AT_CHECK(QGREP(foobar test_dir10/MT/options))
AT_CLEANUP
========================================================================
--- tests/t_commit_log_1.at 7c5599e3f7447950849b3f22dfa8e2b2e2acaea2
+++ tests/t_commit_log_1.at 7f484d7237acc02b49235fcbd05fee00fb3ff4e7
@@ -23,6 +23,6 @@
TSHA=`BASE_REVISION`
AT_CHECK(test -f MT/log -a ! -s MT/log)
AT_CHECK(MONOTONE ls certs $TSHA, [], [stdout], [ignore])
-AT_CHECK(grep -q 'Log entry' stdout, [])
+AT_CHECK(QGREP('Log entry' stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_commit_log_2.at 444dccb6fe68c8c56974c997843ad9e986c3d553
+++ tests/t_commit_log_2.at 367f752f3e6fe48cdb41a182b9428129d32de8ee
@@ -15,6 +15,6 @@
TSHA=`BASE_REVISION`
AT_CHECK(MONOTONE ls certs $TSHA, [], [stdout], [ignore])
-AT_CHECK(grep -q 'Log entry' stdout, [])
+AT_CHECK(QGREP('Log entry' stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_commit_message_file.at a44df1257c0a0400d00f6876f1c82eb64b0466ac
+++ tests/t_commit_message_file.at aa49a6a98a40d510813800cd39cf9ae399bef4ed
@@ -20,7 +20,7 @@
TSHA=`BASE_REVISION`
AT_CHECK(MONOTONE ls certs $TSHA, [], [stdout], [ignore])
-AT_CHECK(grep -q 'this commit uses the --message-file option' stdout, [])
+AT_CHECK(QGREP('this commit uses the --message-file option' stdout), [])
#--------------------
#also with a file coming outside the working copy
@@ -39,7 +39,7 @@
TSHA=`cd alt_wrk && BASE_REVISION`
AT_CHECK(cd alt_wrk && MONOTONE ls certs $TSHA, [], [stdout], [ignore])
-AT_CHECK(grep -q 'out out out' stdout, [])
+AT_CHECK(QGREP('out out out' stdout), [])
#--------------------
#start with the failures: non existing file
========================================================================
--- tests/t_cvsimport2.at 041a3f5713eec32152977b2dd410da42e7fa61b4
+++ tests/t_cvsimport2.at a149cb06fc8e5edc8ad655187e92c2082b050564
@@ -7,7 +7,8 @@
# Make sure we handle it correct.
AT_DATA(prepare.sh,[#!/bin/sh
-export CVSROOT=$PWD/cvsroot
+CVSROOT=$PWD/cvsroot
+export CVSROOT
cvs init
mkdir src
========================================================================
--- tests/t_database_check_minor.at eaba52f05e60be3f4bfc420af0722fd5ed63df02
+++ tests/t_database_check_minor.at c3716a80023cce652e10ebebb1df1e405a9d86ca
@@ -33,8 +33,8 @@
AT_CHECK(MONOTONE db check, [], [ignore], [stderr])
-AT_CHECK(grep -q 'problems detected: 3' stderr)
-AT_CHECK(grep -q '0 serious' stderr)
-AT_CHECK(grep -q 'minor problems detected' stderr)
+AT_CHECK(QGREP('problems detected: 3' stderr))
+AT_CHECK(QGREP('0 serious' stderr))
+AT_CHECK(QGREP('minor problems detected' stderr))
AT_CLEANUP
========================================================================
--- tests/t_db_execute.at 992a2c0fe487f6ac987a168084e65c2c4636e91b
+++ tests/t_db_execute.at cad25454a737ae7296cf95712501b7320b4e3898
@@ -7,24 +7,24 @@
AT_CHECK(MONOTONE db execute "INSERT INTO $TWO_COL_TABLE VALUES ('key1', 'value1')", [], [ignore], [ignore])
AT_CHECK(MONOTONE db execute "SELECT * FROM $TWO_COL_TABLE", [], [stdout], [ignore])
-AT_CHECK(grep -q key1 stdout)
-AT_CHECK(grep -q value1 stdout)
+AT_CHECK(QGREP(key1 stdout))
+AT_CHECK(QGREP(value1 stdout))
AT_CHECK(MONOTONE db execute "SELECT * FROM $TWO_COL_TABLE WHERE $COL1 = 'nonsense'", [], [stdout], [ignore])
-AT_CHECK(grep -q key1 stdout, [1])
+AT_CHECK(QGREP(key1 stdout), [1])
AT_CHECK(MONOTONE db execute "SELECT * FROM $TWO_COL_TABLE WHERE $COL1 LIKE 'k%'", [], [stdout], [ignore])
-AT_CHECK(grep -q key1 stdout)
+AT_CHECK(QGREP(key1 stdout))
AT_CHECK(MONOTONE db execute "DELETE FROM $TWO_COL_TABLE", [], [ignore], [ignore])
AT_CHECK(MONOTONE db execute "SELECT * FROM $TWO_COL_TABLE", [], [stdout], [ignore])
-AT_CHECK(grep -q key1 stdout, [1])
+AT_CHECK(QGREP(key1 stdout), [1])
# We used to have weird quoting bugs around "%"
# string is split into two so the grep doesn't trigger on monotone's
# chatter about what command it's going to execute...
AT_CHECK(MONOTONE db execute "SELECT '%s' || 'tuff'", [], [stdout], [ignore])
-AT_CHECK(grep -q '%stuff' stdout)
+AT_CHECK(QGREP('%stuff' stdout))
AT_CLEANUP
========================================================================
--- tests/t_db_kill_branch_certs_locally.at 7821995222e42c3f8c89753df9168eebe27e0a8b
+++ tests/t_db_kill_branch_certs_locally.at 4b77eb010e0fad546869da1d6af69d0a1a81d36d
@@ -10,14 +10,14 @@
REVISION=`BASE_REVISION`
AT_CHECK(MONOTONE cert $REVISION branch bad, [], ignore, ignore)
AT_CHECK(MONOTONE ls branches, [], stdout, ignore)
-AT_CHECK(grep -q good stdout)
-AT_CHECK(grep -q bad stdout)
+AT_CHECK(QGREP(good stdout))
+AT_CHECK(QGREP(bad stdout))
# Now we delete the branch, and make sure it's gone
AT_CHECK(MONOTONE db kill_branch_certs_locally bad, [], ignore, ignore)
AT_CHECK(MONOTONE ls branches, [], stdout, ignore)
-AT_CHECK(grep -q good stdout)
-AT_CHECK(grep -q bad stdout, [1])
+AT_CHECK(QGREP(good stdout))
+AT_CHECK(QGREP(bad stdout), [1])
# And lets make sure our database is still OK
AT_CHECK(MONOTONE db check, [], ignore, ignore)
========================================================================
--- tests/t_diff_external.at d05dbe56b40eadaac3018fec89ffda8640f59f23
+++ tests/t_diff_external.at e4c70aa4c4144040ea0b027948f6a8dc98a55ae9
@@ -33,33 +33,33 @@
AT_CHECK(CANONICALISE(stdout))
AT_CHECK(CANONICALISE(old_version))
AT_CHECK(CANONICALISE(new_version))
-AT_CHECK(grep -q 'file_path: testfile' stdout)
+AT_CHECK(QGREP('file_path: testfile' stdout))
AT_CHECK(cmp old_version old_testfile)
AT_CHECK(cmp new_version testfile)
-AT_CHECK(grep -q 'diff_args is NIL' stdout)
-AT_CHECK(grep -q "rev_old: $OLD_SHA" stdout)
-AT_CHECK(grep -q "rev_new: $NEW_SHA" stdout)
+AT_CHECK(QGREP('diff_args is NIL' stdout))
+AT_CHECK(QGREP("rev_old: $OLD_SHA" stdout))
+AT_CHECK(QGREP("rev_new: $NEW_SHA" stdout))
AT_CHECK(MONOTONE --rcfile=testhook.lua diff --external --diff-args="-foobar", [], [stdout], [ignore])
AT_CHECK(CANONICALISE(stdout))
AT_CHECK(CANONICALISE(old_version))
AT_CHECK(CANONICALISE(new_version))
-AT_CHECK(grep -q 'file_path: testfile' stdout)
+AT_CHECK(QGREP('file_path: testfile' stdout))
AT_CHECK(cmp old_version old_testfile)
AT_CHECK(cmp new_version testfile)
-AT_CHECK(grep -q 'diff_args: -foobar' stdout)
-AT_CHECK(grep -q "rev_old: $OLD_SHA" stdout)
-AT_CHECK(grep -q "rev_new: $NEW_SHA" stdout)
+AT_CHECK(QGREP('diff_args: -foobar' stdout))
+AT_CHECK(QGREP("rev_old: $OLD_SHA" stdout))
+AT_CHECK(QGREP("rev_new: $NEW_SHA" stdout))
AT_CHECK(MONOTONE --rcfile=testhook.lua diff --external --diff-args="", [], [stdout], [ignore])
AT_CHECK(CANONICALISE(stdout))
AT_CHECK(CANONICALISE(old_version))
AT_CHECK(CANONICALISE(new_version))
-AT_CHECK(grep -q 'file_path: testfile' stdout)
+AT_CHECK(QGREP('file_path: testfile' stdout))
AT_CHECK(cmp old_version old_testfile)
AT_CHECK(cmp new_version testfile)
-AT_CHECK(egrep -q '^diff_args: $' stdout)
-AT_CHECK(grep -q "rev_old: $OLD_SHA" stdout)
-AT_CHECK(grep -q "rev_new: $NEW_SHA" stdout)
+AT_CHECK(QEGREP('^diff_args: $' stdout))
+AT_CHECK(QGREP("rev_old: $OLD_SHA" stdout))
+AT_CHECK(QGREP("rev_new: $NEW_SHA" stdout))
AT_CLEANUP
========================================================================
--- tests/t_diff_first_rev.at 45914ceefd54646b62ee8e2cc68a92f2f7d1666d
+++ tests/t_diff_first_rev.at 6ae8976a600c70b0ddaba8ed4e399037685fe968
@@ -1,10 +1,10 @@
AT_SETUP([diff in a never-committed project])
MONOTONE_SETUP
ADD_FILE(testfile, [flagella
])
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q testfile stdout)
-AT_CHECK(grep -q flagella stdout)
+AT_CHECK(QGREP(testfile stdout))
+AT_CHECK(QGREP(flagella stdout))
AT_CLEANUP
========================================================================
--- tests/t_diff_restrict.at 12d098b7ad489c927d48c3e3be5a5ea5fb122213
+++ tests/t_diff_restrict.at ee27d0b0ec717a1ca9a88009ace00ecd56e75370
@@ -22,18 +22,18 @@
AT_CHECK(MONOTONE diff file1, [], [stdout], [ignore])
AT_CHECK(grep file1 stdout, [], [ignore], [ignore])
-AT_CHECK(grep -q file2 stdout, [1], [ignore], [ignore])
+AT_CHECK(QGREP(file2 stdout), [1], [ignore], [ignore])
AT_CHECK(MONOTONE diff --revision=$REV0 file1, [], [stdout], [ignore])
AT_CHECK(grep file1 stdout, [], [ignore], [ignore])
-AT_CHECK(grep -q file2 stdout, [1], [ignore], [ignore])
+AT_CHECK(QGREP(file2 stdout), [1], [ignore], [ignore])
AT_CHECK(MONOTONE diff --revision=$REV0 --revision=$REV1 file1, [], [stdout], [ignore])
AT_CHECK(grep file1 stdout, [], [ignore], [ignore])
-AT_CHECK(grep -q file2 stdout, [1], [ignore], [ignore])
+AT_CHECK(QGREP(file2 stdout), [1], [ignore], [ignore])
AT_CHECK(MONOTONE diff --revision=$REV1 --revision=$REV0 file1, [], [stdout], [ignore])
AT_CHECK(grep file1 stdout, [], [ignore], [ignore])
-AT_CHECK(grep -q file2 stdout, [1], [ignore], [ignore])
+AT_CHECK(QGREP(file2 stdout), [1], [ignore], [ignore])
AT_CLEANUP
========================================================================
--- tests/t_drop_attr.at a88f420f9e89876865d487e8d16fa0d76a117c01
+++ tests/t_drop_attr.at edb460d1adb623cf01b29f6945af549becb263d5
@@ -5,14 +5,14 @@
])
AT_CHECK(MONOTONE attr set testfile some_key some_value, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q some_key stdout)
-AT_CHECK(grep -q some_value stdout)
+AT_CHECK(QGREP(some_key stdout))
+AT_CHECK(QGREP(some_value stdout))
COMMIT(testbranch)
AT_CHECK(MONOTONE drop testfile, [], [ignore], [ignore])
AT_CHECK(MONOTONE attr get testfile, [], [stdout], [ignore])
-AT_CHECK(grep -q some_key stdout, [1])
-AT_CHECK(grep -q some_value stdout, [1])
+AT_CHECK(QGREP(some_key stdout), [1])
+AT_CHECK(QGREP(some_value stdout), [1])
AT_CLEANUP
========================================================================
--- tests/t_dropkey_1.at b60d83a960145f795130597f4fc48b0f773429fa
+++ tests/t_dropkey_1.at 87e5a23e7ed8df5db283b295648832ef72b0f5f7
@@ -15,12 +15,12 @@
AT_CHECK(MONOTONE pubkey address@hidden, [], [stdout], [ignore])
-AT_CHECK(grep -q 'address@hidden' stdout, [])
+AT_CHECK(QGREP('address@hidden' stdout), [])
AT_CHECK(MONOTONE dropkey address@hidden, [], [ignore], [ignore])
AT_CHECK(MONOTONE pubkey address@hidden, [1], [ignore], [stderr])
-AT_CHECK(grep -q 'does not exist' stderr, [])
+AT_CHECK(QGREP('does not exist' stderr), [])
AT_CLEANUP
========================================================================
--- tests/t_dropkey_2.at 273fd69925b633a137a326975a2ba6a1d1f45293
+++ tests/t_dropkey_2.at 52a101950139d3799bf23b1f789de3503d37741f
@@ -29,16 +29,16 @@
AT_CHECK(MONOTONE privkey address@hidden, [], [stdout], [ignore])
-AT_CHECK(grep -q 'address@hidden' stdout, [])
+AT_CHECK(QGREP('address@hidden' stdout), [])
AT_CHECK(MONOTONE dropkey address@hidden, [], [ignore], [ignore])
AT_CHECK(MONOTONE privkey address@hidden, [1], [ignore], [stderr])
-AT_CHECK(grep -q 'do not exist' stderr, [])
+AT_CHECK(QGREP('do not exist' stderr), [])
AT_CHECK(MONOTONE pubkey address@hidden, [1], [ignore], [stderr])
-AT_CHECK(grep -q 'does not exist' stderr, [])
+AT_CHECK(QGREP('does not exist' stderr), [])
AT_CLEANUP
========================================================================
--- tests/t_existsonpath.at 3bbd717c0872f45e088cd95b692a1fc0c649583f
+++ tests/t_existsonpath.at fc7253fa711c37e25ffdd8e0aa90a631286926f5
@@ -16,7 +16,7 @@
end
])
AT_CHECK(MONOTONE setup --rcfile=test.lua subdir, [], [stdout], [ignore])
-AT_CHECK(grep -q asdfghjkl stdout, [])
-AT_CHECK(grep -q qwertyuiop stdout, [])
+AT_CHECK(QGREP(asdfghjkl stdout), [])
+AT_CHECK(QGREP(qwertyuiop stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_heads.at b5f1e0cc996bc9356d0bfd6189b3f7a7e9287a91
+++ tests/t_heads.at de84bc0854989c38fb5d424a87eef0f9964c4cab
@@ -17,7 +17,7 @@
ROOT_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout))
# Create a child
#
@@ -33,8 +33,8 @@
CHILD1_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout))
# Create another child
#
@@ -51,9 +51,9 @@
CHILD2_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout)
-AT_CHECK(grep -q $CHILD2_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout))
+AT_CHECK(QGREP($CHILD2_R_SHA stdout))
# Branch from the second child into branch2
#
@@ -72,15 +72,15 @@
CHILD3_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout)
-AT_CHECK(grep -q $CHILD2_R_SHA stdout)
-AT_CHECK(grep -q $CHILD3_R_SHA stdout, [1])
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout))
+AT_CHECK(QGREP($CHILD2_R_SHA stdout))
+AT_CHECK(QGREP($CHILD3_R_SHA stdout), [1])
AT_CHECK(MONOTONE --branch=branch2 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD2_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD3_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD2_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD3_R_SHA stdout))
# Branch from the first child into branch2
#
@@ -100,16 +100,16 @@
CHILD4_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout)
-AT_CHECK(grep -q $CHILD2_R_SHA stdout)
-AT_CHECK(grep -q $CHILD3_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD4_R_SHA stdout, [1])
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout))
+AT_CHECK(QGREP($CHILD2_R_SHA stdout))
+AT_CHECK(QGREP($CHILD3_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD4_R_SHA stdout), [1])
AT_CHECK(MONOTONE --branch=branch2 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD2_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD3_R_SHA stdout)
-AT_CHECK(grep -q $CHILD4_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD2_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD3_R_SHA stdout))
+AT_CHECK(QGREP($CHILD4_R_SHA stdout))
AT_CLEANUP
========================================================================
--- tests/t_heads_discontinuous_branch.at 8c830776ab70d8775298aac86e89f32f98922d3f
+++ tests/t_heads_discontinuous_branch.at c76e752a9c3d9bff30e7a0eb511de7f50eab9f07
@@ -22,7 +22,7 @@
# Sanity check first...
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1_R_SHA stdout)
+AT_CHECK(QGREP($R1_R_SHA stdout))
# Now create R2
AT_DATA(f, [r2 data
@@ -38,8 +38,8 @@
# Now check heads on branch1
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1_R_SHA stdout, [1])
-AT_CHECK(grep -q $R2_R_SHA stdout, [1])
-AT_CHECK(grep -q $R3_R_SHA stdout, [0])
+AT_CHECK(QGREP($R1_R_SHA stdout), [1])
+AT_CHECK(QGREP($R2_R_SHA stdout), [1])
+AT_CHECK(QGREP($R3_R_SHA stdout), [0])
AT_CLEANUP
========================================================================
--- tests/t_inodeprints.at 6fa42cdc469696e818f9df7569c9c0412117da42
+++ tests/t_inodeprints.at d67a539bc4da605a1959d597bf5747557bc3548f
@@ -5,13 +5,13 @@
AT_CHECK(touch MT/inodeprints)
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q "no changes" stdout)
+AT_CHECK(QGREP("no changes" stdout))
ADD_FILE(testfile, [blah blah
])
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q "blah blah" stdout)
+AT_CHECK(QGREP("blah blah" stdout))
COMMIT(testbranch)
@@ -21,13 +21,13 @@
# And stuff should still work
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q "no changes" stdout)
+AT_CHECK(QGREP("no changes" stdout))
SET_FILE(testfile, [stuff stuff
])
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q "stuff stuff" stdout)
+AT_CHECK(QGREP("stuff stuff" stdout))
# Make sure partial commit doesn't screw things up
ADD_FILE(otherfile, [other stuff
@@ -39,6 +39,6 @@
# Still should think testfile is modified
AT_CHECK(MONOTONE diff, [], [stdout], [ignore])
-AT_CHECK(grep -q "stuff stuff" stdout)
+AT_CHECK(QGREP("stuff stuff" stdout))
AT_CLEANUP
========================================================================
--- tests/t_kill_tag_locally.at b091837656ce01a0b6ecf80706725d3251e00abf
+++ tests/t_kill_tag_locally.at 62be6ee4e44142ec69963f446c196ade4a71174c
@@ -27,37 +27,37 @@
AT_CHECK(MONOTONE tag $R4 other_tag, [], [ignore], [ignore])
AT_CHECK(MONOTONE ls tags, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1 stdout, [])
-AT_CHECK(grep -q ambig_tag stdout, [])
-AT_CHECK(grep -q $R2 stdout, [])
-AT_CHECK(grep -q ambig_tag stdout, [])
-AT_CHECK(grep -q $R3 stdout, [])
-AT_CHECK(grep -q test_tag stdout, [])
-AT_CHECK(grep -q $R4 stdout, [])
-AT_CHECK(grep -q other_tag stdout, [])
+AT_CHECK(QGREP($R1 stdout), [])
+AT_CHECK(QGREP(ambig_tag stdout), [])
+AT_CHECK(QGREP($R2 stdout), [])
+AT_CHECK(QGREP(ambig_tag stdout), [])
+AT_CHECK(QGREP($R3 stdout), [])
+AT_CHECK(QGREP(test_tag stdout), [])
+AT_CHECK(QGREP($R4 stdout), [])
+AT_CHECK(QGREP(other_tag stdout), [])
AT_CHECK(MONOTONE db kill_tag_locally test_tag, [], [ignore], [ignore])
AT_CHECK(MONOTONE ls tags, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1 stdout, [])
-AT_CHECK(grep -q ambig_tag stdout, [])
-AT_CHECK(grep -q $R2 stdout, [])
-AT_CHECK(grep -q ambig_tag stdout, [])
-AT_CHECK(grep -q $R3 stdout, [1])
-AT_CHECK(grep -q test_tag stdout, [1])
-AT_CHECK(grep -q $R4 stdout, [])
-AT_CHECK(grep -q other_tag stdout, [])
+AT_CHECK(QGREP($R1 stdout), [])
+AT_CHECK(QGREP(ambig_tag stdout), [])
+AT_CHECK(QGREP($R2 stdout), [])
+AT_CHECK(QGREP(ambig_tag stdout), [])
+AT_CHECK(QGREP($R3 stdout), [1])
+AT_CHECK(QGREP(test_tag stdout), [1])
+AT_CHECK(QGREP($R4 stdout), [])
+AT_CHECK(QGREP(other_tag stdout), [])
AT_CHECK(MONOTONE db kill_tag_locally ambig_tag, [], [ignore], [ignore])
AT_CHECK(MONOTONE ls tags, [], [stdout], [ignore])
-AT_CHECK(grep -q $R1 stdout, [1])
-AT_CHECK(grep -q ambig_tag stdout, [1])
-AT_CHECK(grep -q $R2 stdout, [1])
-AT_CHECK(grep -q ambig_tag stdout, [1])
-AT_CHECK(grep -q $R3 stdout, [1])
-AT_CHECK(grep -q test_tag stdout, [1])
-AT_CHECK(grep -q $R4 stdout, [])
-AT_CHECK(grep -q other_tag stdout, [])
+AT_CHECK(QGREP($R1 stdout), [1])
+AT_CHECK(QGREP(ambig_tag stdout), [1])
+AT_CHECK(QGREP($R2 stdout), [1])
+AT_CHECK(QGREP(ambig_tag stdout), [1])
+AT_CHECK(QGREP($R3 stdout), [1])
+AT_CHECK(QGREP(test_tag stdout), [1])
+AT_CHECK(QGREP($R4 stdout), [])
+AT_CHECK(QGREP(other_tag stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_lua_includedir.at 5b4ce1e6a2781a7a841039a1e02a96cc0221f3ff
+++ tests/t_lua_includedir.at 06e756a957d1d330d347970c0c32def0936c7702
@@ -26,11 +26,11 @@
# include directly a single file
AT_CHECK(cd alt_wrk && MONOTONE --root=. --rcfile=../include.lua status, [], [stdout], [ignore])
-AT_CHECK(grep -q "BOOGA BOOGA" stdout)
+AT_CHECK(QGREP("BOOGA BOOGA" stdout))
# include dirs
AT_CHECK(cd alt_wrk && MONOTONE --root=. --rcfile=../includedir.lua status, [], [stdout], [ignore])
-AT_CHECK(grep -q "BOOGA BOOGACICCA CICCA" stdout)
+AT_CHECK(QGREP("BOOGA BOOGACICCA CICCA" stdout))
# write a third file: should be read beetween the two previous ones
AT_DATA(gongolo/aba.rc, [function notwowithoutthree()
@@ -39,6 +39,6 @@
notwowithoutthree()
])
AT_CHECK(cd alt_wrk && MONOTONE --root=. --rcfile=../includedir.lua status, [], [stdout], [ignore])
-AT_CHECK(grep -q "BOOGA BOOGAhu huCICCA CICCA" stdout)
+AT_CHECK(QGREP("BOOGA BOOGAhu huCICCA CICCA" stdout))
AT_CLEANUP
========================================================================
--- tests/t_merge_lca.at b3836fc9531f92a6fb429e97c0c3076dadc80aeb
+++ tests/t_merge_lca.at b91ca296740e117ca8a8a2f86fad02764f126f07
@@ -45,7 +45,7 @@
E=`BASE_REVISION`
AT_CHECK(MONOTONE merge --lca, [], [ignore], [stderr])
-AT_CHECK(grep -q $A stderr, [1])
-AT_CHECK(grep -q $B stderr || grep -q $C stderr, [])
+AT_CHECK(QGREP($A stderr), [1])
+AT_CHECK(QGREP($B stderr) || QGREP($C stderr), [])
AT_CLEANUP
========================================================================
--- tests/t_migrate_schema.at a5021d066df05e23620346dbc5cf480377af160f
+++ tests/t_migrate_schema.at 2074b20ad00853b9490ce370b6e6002bf2fe52f2
@@ -112,7 +112,7 @@
AT_CHECK(MONOTONE --db=$1.db db load < $1.db.dumped, [], [ignore], [ignore])
# verify that the db actually has the claimed schema
AT_CHECK(MONOTONE --db=$1.db db version, [], [stdout], [ignore])
-AT_CHECK(grep -q $1 stdout)
+AT_CHECK(QGREP($1 stdout))
# now do the actual migration
AT_CHECK(MONOTONE --db=$1.db db migrate, [], [ignore], [ignore])
CHECK_SAME_DB_CONTENTS($1.db, latest.db)
========================================================================
--- tests/t_multiple_heads_msg.at e662d7470063759b847c0d98362dddb90ee7d0b6
+++ tests/t_multiple_heads_msg.at e18276c0c4588a1bac33d4db0f84921eee8419a1
@@ -15,11 +15,11 @@
AT_CHECK(MONOTONE add f, [], [ignore], [ignore])
AT_CHECK(MONOTONE --branch=branch1 commit --message blah-blah, [], [ignore], [stderr])
-AT_CHECK(grep -q 'creates divergence' stderr, [1])
+AT_CHECK(QGREP('creates divergence' stderr), [1])
ROOT_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout))
# Create a child
#
@@ -32,12 +32,12 @@
AT_DATA(f, [child1 data
])
AT_CHECK(MONOTONE --branch=branch1 commit --message blah-blah, [], [ignore], [stderr])
-AT_CHECK(grep -q 'creates divergence' stderr, [1])
+AT_CHECK(QGREP('creates divergence' stderr), [1])
CHILD1_R_SHA=`BASE_REVISION`
AT_CHECK(MONOTONE --branch=branch1 heads, [], [stdout], [ignore])
-AT_CHECK(grep -q $ROOT_R_SHA stdout, [1])
-AT_CHECK(grep -q $CHILD1_R_SHA stdout)
+AT_CHECK(QGREP($ROOT_R_SHA stdout), [1])
+AT_CHECK(QGREP($CHILD1_R_SHA stdout))
# Create another child
#
@@ -52,10 +52,10 @@
])
AT_CHECK(MONOTONE --branch=branch1 commit --message blah-blah, [], [ignore], [stderr])
CHILD2_R_SHA=`BASE_REVISION`
-AT_CHECK(grep -q 'this revision creates divergence' stderr, [])
+AT_CHECK(QGREP('this revision creates divergence' stderr), [])
AT_CHECK(MONOTONE --branch=branch1 update, [], [ignore], [stderr])
-AT_CHECK(grep -q 'has multiple heads' stderr, [])
+AT_CHECK(QGREP('has multiple heads' stderr), [])
# Create a new branch
#
@@ -74,7 +74,7 @@
])
AT_CHECK(MONOTONE --branch=branch2 commit --message blah-blah, [], [ignore], [stderr])
NEW1_R_SHA=`BASE_REVISION`
-AT_CHECK(grep -q 'this revision creates divergence' stderr, [1])
+AT_CHECK(QGREP('this revision creates divergence' stderr), [1])
REVERT_TO($CHILD2_R_SHA)
@@ -82,6 +82,6 @@
])
AT_CHECK(MONOTONE --branch=branch2 commit --message blah-blah, [], [ignore], [stderr])
NEW2_R_SHA=`BASE_REVISION`
-AT_CHECK(grep -q 'this revision creates divergence' stderr, [])
+AT_CHECK(QGREP('this revision creates divergence' stderr), [])
AT_CLEANUP
========================================================================
--- tests/t_netsync_exclude.at eea97484d1bd402e60fe263d96416c58cd09e96f
+++ tests/t_netsync_exclude.at 5a8302a38e8e62edb41b4332822cf82458177d85
@@ -42,7 +42,7 @@
AT_CHECK(MONOTONE2 cat revision $B3, [], [ignore], [ignore])
AT_CHECK(MONOTONE2 cat revision $B4, [1], [ignore], [ignore])
-AT_CHECK(MONOTONE2 ls certs $B2 | grep -q branch2, [1])
+AT_CHECK(MONOTONE2 ls certs $B2 | QGREP(branch2), [1])
NETSYNC_SERVE_STOP
========================================================================
--- tests/t_netsync_pubkey.at e4619acef738ea59b9ba6cc957bc20dd20a465cf
+++ tests/t_netsync_pubkey.at 61ed3de939144d8bd75884dc842a4dfde299ac96
@@ -39,8 +39,8 @@
RUN_NETSYNC(pull, testbranch)
AT_CHECK(MONOTONE2 ls keys, [], [stdout], [ignore])
-AT_CHECK(grep -q $PUBKEY stdout, [1])
-AT_CHECK(grep -q $PRIVKEY stdout, [1])
+AT_CHECK(QGREP($PUBKEY stdout), [1])
+AT_CHECK(QGREP($PRIVKEY stdout), [1])
# Now commit a version that does use the new key, and make sure that
# now it does get transferred.
@@ -51,7 +51,7 @@
RUN_NETSYNC(pull, testbranch)
AT_CHECK(MONOTONE2 ls keys, [], [stdout], [ignore])
-AT_CHECK(grep -q $PUBKEY stdout)
-AT_CHECK(grep -q $PRIVKEY stdout, [1])
+AT_CHECK(QGREP($PUBKEY stdout))
+AT_CHECK(QGREP($PRIVKEY stdout), [1])
AT_CLEANUP
========================================================================
--- tests/t_netsync_read_permissions.at b25f34bb748f72ffa5cdfe08f91d982c2b87eaff
+++ tests/t_netsync_read_permissions.at 0550bdeac357f6794dd4849b2f0c0ba05a8c6286
@@ -48,7 +48,7 @@
AT_CHECK(MONOTONE2 cat revision $B3, [], [ignore], [ignore])
AT_CHECK(MONOTONE2 cat revision $B4, [1], [ignore], [ignore])
-AT_CHECK(MONOTONE2 ls certs $B2 | grep -q branch2, [1])
+AT_CHECK(MONOTONE2 ls certs $B2 | QGREP(branch2), [1])
NETSYNC_SERVE_STOP
========================================================================
--- tests/t_no_change_deltas.at 41f660ced1f5900ec5a839e8920a8e4b3cd70fcd
+++ tests/t_no_change_deltas.at 3f44bcd2b864ef0d1294d6609d0880b61dfd4de7
@@ -35,10 +35,10 @@
AT_CHECK(test $BASE_F_SHA = $NEW_F_SHA)
AT_CHECK(MONOTONE diff --revision $BASE --revision $NEW, [], [stdout], [ignore])
-AT_CHECK(grep -q $NEW_OTHER_SHA stdout)
-AT_CHECK(grep -q $BASE_F_SHA stdout, [1])
+AT_CHECK(QGREP($NEW_OTHER_SHA stdout))
+AT_CHECK(QGREP($BASE_F_SHA stdout), [1])
AT_CHECK(MONOTONE diff --revision $NEW --revision $BASE, [], [stdout], [ignore])
-AT_CHECK(grep -q $BASE_OTHER_SHA stdout)
-AT_CHECK(grep -q $BASE_F_SHA stdout, [1])
+AT_CHECK(QGREP($BASE_OTHER_SHA stdout))
+AT_CHECK(QGREP($BASE_F_SHA stdout), [1])
AT_CLEANUP
========================================================================
--- tests/t_normalized_filenames.at 5e0d909dd5f1dbd5502d327e94a108bcc60bec74
+++ tests/t_normalized_filenames.at 7b5a8ccabc5c0fea6a19cc901373c9336be7af59
@@ -15,11 +15,11 @@
])
AT_CHECK(MONOTONE cat manifest, [], [stdout], [ignore])
-AT_CHECK(grep -q ' bar' stdout)
+AT_CHECK(QGREP(' bar' stdout))
AT_CHECK(MONOTONE cat revision, [], [stdout], [ignore])
-AT_CHECK(grep -q '"bar"' stdout)
+AT_CHECK(QGREP('"bar"' stdout))
AT_CHECK(MONOTONE commit --message=foo --branch=foo, [], [ignore], [ignore])
AT_CHECK(MONOTONE cat revision `BASE_REVISION`, [], [stdout], [ignore])
-AT_CHECK(grep -q '"bar"' stdout)
+AT_CHECK(QGREP('"bar"' stdout))
AT_CLEANUP
========================================================================
--- tests/t_override_author_date.at e16cba63a1e9ce16356e6ae32fd95a89a13b79f2
+++ tests/t_override_author_date.at 28f11d05555f865105d40e0ec0b3454043082750
@@ -7,8 +7,8 @@
REV=`BASE_REVISION`
AT_CHECK(MONOTONE log --revision=$REV, [], [stdout], [ignore])
-AT_CHECK(grep -q '^Author: the_author' stdout)
-AT_CHECK(grep -q '^Date: 1999-12-31T12:00:00' stdout)
+AT_CHECK(QGREP('^Author: the_author' stdout))
+AT_CHECK(QGREP('^Date: 1999-12-31T12:00:00' stdout))
SET_FILE(testfile, [oovel
])
========================================================================
--- tests/t_persistent_server_keys.at 9f7d8f9f1f3b0b8eb790534c8b14939d62595ccf
+++ tests/t_persistent_server_keys.at 3b2ee5cc35e8e124a22a00d334a5c9bcfeac4101
@@ -18,7 +18,7 @@
NETSYNC_CLIENT_N_RUN(3, pull, testbranch)
AT_CHECK(MONOTONE3 ls keys, [], [stdout], [ignore])
-AT_CHECK(grep -q address@hidden stdout, [1])
+AT_CHECK(QGREP(address@hidden stdout), [1])
AT_DATA(testfile, [stuffty stuffty
])
@@ -30,6 +30,6 @@
NETSYNC_SERVE_STOP
AT_CHECK(MONOTONE3 ls keys, [], [stdout], [ignore])
-AT_CHECK(grep -q address@hidden stdout)
+AT_CHECK(QGREP(address@hidden stdout))
AT_CLEANUP
========================================================================
--- tests/t_persistent_server_keys_2.at 996841cb3e53d98bf67aa1a92c2d571235eed71e
+++ tests/t_persistent_server_keys_2.at f974ca0aba33b2107a1fd7677ded50faa52b3a05
@@ -33,6 +33,6 @@
NETSYNC_SERVE_STOP
AT_CHECK(MONOTONE3 ls keys, [], [stdout], [ignore])
-AT_CHECK(grep -q address@hidden stdout, [])
+AT_CHECK(QGREP(address@hidden stdout), [])
AT_CLEANUP
========================================================================
--- tests/t_propagate_desc.at 282d88d1143283a8cfcc14a12456d97d09349ea3
+++ tests/t_propagate_desc.at b03a137a514b121a1ba4ae31b63b86ee37f2cdb8
@@ -26,8 +26,8 @@
AT_CHECK(MONOTONE propagate b a, [], [ignore], [ignore])
AT_CHECK(MONOTONE heads --branch=b, [], [stdout], [ignore])
-AT_CHECK(grep -q $B_HEAD_REV stdout)
+AT_CHECK(QGREP($B_HEAD_REV stdout))
AT_CHECK(MONOTONE heads --branch=a, [], [stdout], [ignore])
-AT_CHECK(grep -q $B_HEAD_REV stdout)
+AT_CHECK(QGREP($B_HEAD_REV stdout))
AT_CLEANUP
========================================================================
--- tests/t_rcfile_dir.at 06128ab21f137c3a69e4fce2db25b0ea3fa424de
+++ tests/t_rcfile_dir.at ef248856acc3362e65a272c54c8ce0131c3aae0f
@@ -18,7 +18,7 @@
# note: rcfile is placed outside workdir
AT_CHECK(MONOTONE setup alt_wrk, [], [ignore], [ignore])
AT_CHECK(cd alt_wrk && MONOTONE --root=. --rcfile=../gongolo status, [], [stdout], [ignore])
-AT_CHECK(grep -q "BOOGA BOOGACICCA CICCA" stdout)
+AT_CHECK(QGREP("BOOGA BOOGACICCA CICCA" stdout))
# write a third file: should be read beetween the two previous ones
AT_DATA(gongolo/aba.rc, [function notwowithoutthree()
@@ -27,6 +27,6 @@
notwowithoutthree()
])
AT_CHECK(cd alt_wrk && MONOTONE --root=. --rcfile=../gongolo status, [], [stdout], [ignore])
-AT_CHECK(grep -q "BOOGA BOOGAhu huCICCA CICCA" stdout)
+AT_CHECK(QGREP("BOOGA BOOGAhu huCICCA CICCA" stdout))
AT_CLEANUP
========================================================================
--- tests/t_rcfile_stdin.at aea482a47a5493616df5dcf06972f174071b3f3a
+++ tests/t_rcfile_stdin.at 09db80cb7bee886ced4c2cb8afbf1be24e04f699
@@ -10,6 +10,6 @@
])
AT_CHECK(@' stdout)
-AT_CHECK(grep -q 'from \@<:@7b675e9ed59eecd9bac3f4ef828196c2069d5a93\@:>@' stdout)
+AT_CHECK(QGREP('new_manifest \@<:@795cf87a1c37f7314f5aa6891e34d267a757fba6\@:>@' stdout))
+AT_CHECK(QGREP('from \@<:@7b675e9ed59eecd9bac3f4ef828196c2069d5a93\@:>@' stdout))
AT_CHECK(MONOTONE db execute "select unbase64('aXQncyB0ZW4gcGFjZXMgbm9ydGh3ZXN0IG9mIHRoZSBwYWxtIHRyZWUuICBGT09CQVI=')", [], [stdout], [ignore])
-AT_CHECK(grep -q FOOBAR stdout)
+AT_CHECK(QGREP(FOOBAR stdout))
AT_CLEANUP
========================================================================
--- tests/t_trusted.at 7f4fd1fc5985d5c185eeed815c70a11c2683442b
+++ tests/t_trusted.at 2ba3de4eef581c8da540326f851df50232d744c2
@@ -1,15 +1,15 @@
AT_SETUP([trust hooks and 'trusted' command])
MONOTONE_SETUP
# run as CHECK_TRUSTED(rev, name, value, signers)
m4_define([CHECK_TRUSTED], [
AT_CHECK(MONOTONE trusted $1 $2 $3 $4, [], [stdout], [ignore])
-AT_CHECK(grep -qi ' trusted' stdout)
+AT_CHECK(QGREP(-i ' trusted' stdout))
])
# run as CHECK_UNTRUSTED(rev, name, value, signers)
m4_define([CHECK_UNTRUSTED], [
AT_CHECK(MONOTONE trusted $1 $2 $3 $4, [], [stdout], [ignore])
-AT_CHECK(grep -qi ' untrusted' stdout)
+AT_CHECK(QGREP(-i ' untrusted' stdout))
])
GOOD=1111111111111111111111111111111111111111
========================================================================
--- tests/t_update_branch.at 0ed6d5a93df9833bcf10e4144e5c6d7fa12a147b
+++ tests/t_update_branch.at b6390318109dc91675aa8a174de4a911cf9c8618
@@ -14,15 +14,15 @@
# candidate, but it's currently at an off-branch revision); and should
# not update the MT/options
AT_CHECK(MONOTONE update -b testbranch, [1], [ignore], [ignore])
-AT_CHECK(grep -q otherbranch MT/options, [])
-AT_CHECK(grep -q testbranch MT/options, [1])
+AT_CHECK(QGREP(otherbranch MT/options), [])
+AT_CHECK(QGREP(testbranch MT/options), [1])
REVERT_TO($REV, testbranch)
-AT_CHECK(grep -q otherbranch MT/options, [1])
-AT_CHECK(grep -q testbranch MT/options, [])
+AT_CHECK(QGREP(otherbranch MT/options), [1])
+AT_CHECK(QGREP(testbranch MT/options), [])
AT_CHECK(MONOTONE update -b otherbranch, [], [ignore], [ignore])
-AT_CHECK(grep -q otherbranch MT/options, [])
-AT_CHECK(grep -q testbranch MT/options, [1])
+AT_CHECK(QGREP(otherbranch MT/options), [])
+AT_CHECK(QGREP(testbranch MT/options), [1])
AT_CLEANUP
========================================================================
--- testsuite.at 278a66fff09e8e04fef830272049d3e88d4f0fc1
+++ testsuite.at 033af1b25953c643786edb6e5c5a2c5b8499c09e
@@ -416,9 +416,12 @@
NETSYNC_CLIENT_RUN($1, $2, 0)
NETSYNC_SERVE_STOP
])
+# run as QGREP(arguments) the same way you'd run 'grep -q arguments'
+# same for QEGREP and egrep -q
+m4_define([QGREP], [grep $1 >/dev/null])
+m4_define([QEGREP], [egrep $1 >/dev/null])
-
# include all the sub-tests we're going to use
m4_include(tests/t_null.at)