Index: diff_tests.py =================================================================== --- diff_tests.py (revision 14458) +++ diff_tests.py (working copy) @@ -17,7 +17,7 @@ ###################################################################### # General modules -import string, sys, re, os.path +import string, sys, re, os.path, datetime,time # Our testing module import svntest @@ -1771,7 +1771,32 @@ raise svntest.Failure +# added diff with time option +def diff_with_time_option(sbox): + "diff with time option" + sbox.build() + wc_dir =sbox.wc_dir + current_dir = os.getcwd() + os.chdir(sbox.wc_dir) + + arg1 = time.strftime('%Y-%m-%d') + arg2 = time.strftime('%H:%M') + arg3 = time.strftime('%Y-%m-%d %H:%M') + arg4 = datetime.datetime.today().isoformat() + + try: + svntest.actions.run_and_verify_svn(None,None,[], + 'diff', '-r','{'+str(arg1)+'}') + svntest.actions.run_and_verify_svn(None,None,[], + 'diff', '-r','{'+str(arg2)+'}') + svntest.actions.run_and_verify_svn(None,None,[], + 'diff', '-r','{'+str(arg3)+'}') + svntest.actions.run_and_verify_svn(None,None,[], + 'diff', '-r','{'+str(arg4)+'}') + finally: + os.chdir(current_dir) + ######################################################################## #Run the tests @@ -1803,7 +1828,8 @@ diff_within_renamed_dir, diff_prop_on_named_dir, diff_keywords, - diff_force + diff_force, + diff_with_time_option ] if __name__ == '__main__':