[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[PATCH] Re: svn commit: r9978 - trunk/tools/test-scripts/svntest

From: Jani Averbach <jaa_at_jaa.iki.fi>
Date: 2004-06-13 22:54:56 CEST

> Log:
> Enable automated testing of trhe FSFS backend and fix a couple of
> bugs in the test scripts.

Few comment:
1) Your change will run fsfs also for 1.0.x
2) It would be nice if the body of messages also will tell which
   REVPREFIX is in use
3) REVPREFIX should be scriptable

Here is a patch to address these issues, how it looks like
(I will clean up REVRPEFIX content for final commit)?

Thanks for doing FSFS integration!

BR, Jani

Log:

Make fsfs testing conditional, and change REVPREFIX declaration place in
svntest-config.sh file, so that it could be scripted.
Use REVPREFIX also for log_file printing.

* tools/test-scripts/svntest/svntest.sh
      Run fsfs tests conditionally depending on value of TEST_FSFS

* tools/test-scripts/svntest/svntest-run.sh
* tools/test-scripts/svntest/svntest-rebuild.sh
     Use REVPREFIX variable for log_file message

* tools/test-scripts/svntest/svntest-config.sh
     (TEST_FSFS): New variable which controls FSFS backend testing
     Move REVPREFIX variable after declaration of command

Patch:
Index: tools/test-scripts/svntest/svntest.sh
===================================================================
--- tools/test-scripts/svntest/svntest.sh (revision 9979)
+++ tools/test-scripts/svntest/svntest.sh (working copy)
@@ -55,20 +55,22 @@
     $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_local" "bdb"
     test $? = 0 && sh_ra_local="PASS" || sh_ra_local="FAIL"
 
- $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_local" "fsfs"
- test $? = 0 && sh_ra_local="PASS" || sh_ra_local="FAIL"
-
     $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_svn" "bdb"
     test $? = 0 && sh_ra_svn="PASS" || sh_ra_svn="FAIL"
 
- $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_svn" "fsfs"
- test $? = 0 && sh_ra_svn="PASS" || sh_ra_svn="FAIL"
-
     $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_dav" "bdb"
     test $? = 0 && sh_ra_dav="PASS" || sh_ra_dav="FAIL"
+
+ test "x$TEST_FSFS" = "xyes" && {
+ $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_local" "fsfs"
+ test $? = 0 && sh_ra_local="PASS" || sh_ra_local="FAIL"
 
- $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_dav" "fsfs"
- test $? = 0 && sh_ra_dav="PASS" || sh_ra_dav="FAIL"
+ $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_svn" "fsfs"
+ test $? = 0 && sh_ra_svn="PASS" || sh_ra_svn="FAIL"
+
+ $NICE $EXEC_PATH/svntest-run.sh "shared" "ra_dav" "fsfs"
+ test $? = 0 && sh_ra_dav="PASS" || sh_ra_dav="FAIL"
+ }
 }
 
 # Test static
@@ -78,15 +80,16 @@
     $NICE $EXEC_PATH/svntest-run.sh "static" "ra_local" "bdb"
     test $? = 0 && st_ra_local="PASS" || st_ra_local="FAIL"
 
- $NICE $EXEC_PATH/svntest-run.sh "static" "ra_local" "fsfs"
- test $? = 0 && st_ra_local="PASS" || st_ra_local="FAIL"
-
     $NICE $EXEC_PATH/svntest-run.sh "static" "ra_svn" "bdb"
     test $? = 0 && st_ra_svn="PASS" || st_ra_svn="FAIL"
 
- $NICE $EXEC_PATH/svntest-run.sh "static" "ra_svn" "fsfs"
- test $? = 0 && st_ra_svn="PASS" || st_ra_svn="FAIL"
+ test "x$TEST_FSFS" = "xyes" && {
+ $NICE $EXEC_PATH/svntest-run.sh "static" "ra_local" "fsfs"
+ test $? = 0 && st_ra_local="PASS" || st_ra_local="FAIL"
 
+ $NICE $EXEC_PATH/svntest-run.sh "static" "ra_svn" "fsfs"
+ test $? = 0 && st_ra_svn="PASS" || st_ra_svn="FAIL"
+ }
 # We have to figure out how the static build of mod_dav_svn should
 # be done, and if it is worth the trouble or not.
 # $NICE $EXEC_PATH/svntest-run.sh "static" "ra_dav" "bdb"
@@ -100,20 +103,24 @@
     $EXEC_PATH/svntest-sendmail.sh "shared" "" "" "$shared"
 test $shared = "PASS" && {
     $EXEC_PATH/svntest-sendmail.sh "shared" "ra_local" "bdb" "$sh_ra_local"
- $EXEC_PATH/svntest-sendmail.sh "shared" "ra_local" "fsfs" "$sh_ra_local"
     $EXEC_PATH/svntest-sendmail.sh "shared" "ra_svn" "bdb" "$sh_ra_svn"
- $EXEC_PATH/svntest-sendmail.sh "shared" "ra_svn" "fsfs" "$sh_ra_svn"
     $EXEC_PATH/svntest-sendmail.sh "shared" "ra_dav" "bdb" "$sh_ra_dav"
- $EXEC_PATH/svntest-sendmail.sh "shared" "ra_dav" "fsfs" "$sh_ra_dav"
+ test "x$TEST_FSFS" = "xyes" && {
+ $EXEC_PATH/svntest-sendmail.sh "shared" "ra_local" "fsfs" "$sh_ra_local"
+ $EXEC_PATH/svntest-sendmail.sh "shared" "ra_svn" "fsfs" "$sh_ra_svn"
+ $EXEC_PATH/svntest-sendmail.sh "shared" "ra_dav" "fsfs" "$sh_ra_dav"
+ }
 }
 
 test $static = "FAIL" && \
     $EXEC_PATH/svntest-sendmail.sh "static" "" "" "$static"
 test $static = "PASS" && {
     $EXEC_PATH/svntest-sendmail.sh "static" "ra_local" "bdb" "$st_ra_local"
- $EXEC_PATH/svntest-sendmail.sh "static" "ra_local" "fsfs" "$st_ra_local"
     $EXEC_PATH/svntest-sendmail.sh "static" "ra_svn" "bdb" "$st_ra_svn"
- $EXEC_PATH/svntest-sendmail.sh "static" "ra_svn" "fsfs" "$st_ra_svn"
+ test "x$TEST_FSFS" = "xyes" && {
+ $EXEC_PATH/svntest-sendmail.sh "static" "ra_local" "fsfs" "$st_ra_local"
+ $EXEC_PATH/svntest-sendmail.sh "static" "ra_svn" "fsfs" "$st_ra_svn"
+ }
 # $EXEC_PATH/svntest-sendmail.sh "static" "ra_dav" "bdb" "$st_ra_dav"
 # $EXEC_PATH/svntest-sendmail.sh "static" "ra_dav" "fsfs" "$st_ra_dav"
 }
Index: tools/test-scripts/svntest/svntest-run.sh
===================================================================
--- tools/test-scripts/svntest/svntest-run.sh (revision 9979)
+++ tools/test-scripts/svntest/svntest-run.sh (working copy)
@@ -16,7 +16,7 @@
 # Prime and initialize the log file
 $CP_F "$LOG_FILE_PREFIX.$BUILD_TYPE" $LOG_FILE
 echo >> $LOG_FILE
-echo "TEST: Revision $REV on $TEST" >> $LOG_FILE
+echo "TEST: $REVPREFIX$REV on $TEST" >> $LOG_FILE
 echo >> $LOG_FILE
 
 # Check the build type
Index: tools/test-scripts/svntest/svntest-config.sh
===================================================================
--- tools/test-scripts/svntest/svntest-config.sh (revision 9979)
+++ tools/test-scripts/svntest/svntest-config.sh (working copy)
@@ -36,6 +36,11 @@
 # RAMDISK=<yes|no>
 RAMDISK=no
 
+#
+# Test or not FSFS backend, TEST_FSFS=<yes|no>
+#
+TEST_FSFS=yes
+
 # This should correspond with your httpd Listen directive
 RA_DAV_CHECK_ARGS="BASE_URL=http://localhost:42024"
 
@@ -60,11 +65,6 @@
 REPLY_TO="dev@subversion.tigris.org"
 
 #
-# Revision number prefix for the e-mail subject
-#
-REVPREFIX="rev "
-
-#
 # Path to utilities
 #
 BIN="/bin"
@@ -142,6 +142,11 @@
 UMOUNT="$BIN/umount"
 
 #
+# Revision number prefix for the e-mail subject
+#
+REVPREFIX="`$SVN info $SVN_REPO | $SED -ne 's!URL.*/repos/svn/\(.*\)!\1!p'` r"
+
+#
 # Helper functions
 #
 
Index: tools/test-scripts/svntest/svntest-rebuild.sh
===================================================================
--- tools/test-scripts/svntest/svntest-rebuild.sh (revision 9979)
+++ tools/test-scripts/svntest/svntest-rebuild.sh (working copy)
@@ -12,7 +12,7 @@
 REV="`$SVN st -v $SVN_REPO/README | $CUT -c 12-17 | $SED -e 's/^ *//'`"
 
 # Initialize the log file
-echo "BUILD: Revision $REV on $BUILD" >> $LOG_FILE
+echo "BUILD: $REVPREFIX$REV on $BUILD" >> $LOG_FILE
 echo >> $LOG_FILE
 
 # Check the build type

-- 
Jani Averbach
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Jun 13 22:55:31 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.