Author: hwright
Date: Wed Jul 7 06:07:44 2010
New Revision: 961247
URL: http://svn.apache.org/viewvc?rev=961247&view=rev
Log:
Add a new test to ensure 'svn cat' handles keyword expansion correctly.
* subversion/tests/cmdline/cat_tests.py
(cat_keywords): New test.
(test_list): Run the new test.
Modified:
subversion/trunk/subversion/tests/cmdline/cat_tests.py
Modified: subversion/trunk/subversion/tests/cmdline/cat_tests.py
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/cat_tests.py?rev=961247&r1=961246&r2=961247&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/cat_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/cat_tests.py Wed Jul 7 06:07:44
2010
@@ -173,6 +173,30 @@ def cat_unversioned_file(sbox):
svntest.actions.run_and_verify_svn2(None, [], expected_error, 0,
'cat', iota_path)
+
+def cat_keywords(sbox):
+ "cat a file with the svn:keywords property"
+ sbox.build()
+ wc_dir = sbox.wc_dir
+ iota_path = os.path.join(wc_dir, 'iota')
+
+ svntest.actions.run_and_verify_svn(None,
+ ["This is the file 'iota'.\n"],
+ [], 'cat', iota_path)
+
+ svntest.main.file_append(iota_path, "$Revision$\n")
+ svntest.actions.run_and_verify_svn(None, None, [],
+ 'propset', 'svn:keywords', 'Revision',
+ iota_path)
+
+ svntest.actions.run_and_verify_svn(None, None, [],
+ 'ci', '-m', 'r2', wc_dir)
+
+ svntest.actions.run_and_verify_svn(None,
+ ["This is the file 'iota'.\n",
"$Revision: 2 $\n"],
+ [], 'cat', iota_path)
+
+
########################################################################
# Run the tests
@@ -185,6 +209,7 @@ test_list = [ None,
cat_nonexistent_file,
cat_skip_uncattable,
cat_unversioned_file,
+ cat_keywords,
]
if __name__ == '__main__':