geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gdam...@apache.org
Subject cvs commit: incubator-geronimo/modules/transaction/src/test/org/apache/geronimo/transaction/manager HOWLLogRecoveryTest.java
Date Wed, 28 Jul 2004 02:12:57 GMT
gdamour     2004/07/27 19:12:57

  Modified:    modules/transaction/src/test/org/apache/geronimo/transaction/manager
                        HOWLLogRecoveryTest.java
  Log:
  Drops the previous transaction log files at the beginning of each test. HOWL was re-using
them between two
  JUnit test executions without a clean in between.
  
  Revision  Changes    Path
  1.5       +10 -2     incubator-geronimo/modules/transaction/src/test/org/apache/geronimo/transaction/manager/HOWLLogRecoveryTest.java
  
  Index: HOWLLogRecoveryTest.java
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/transaction/src/test/org/apache/geronimo/transaction/manager/HOWLLogRecoveryTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- HOWLLogRecoveryTest.java	25 Jun 2004 21:29:34 -0000	1.4
  +++ HOWLLogRecoveryTest.java	28 Jul 2004 02:12:57 -0000	1.5
  @@ -43,12 +43,20 @@
       }
   
       protected void setUp() throws Exception {
  +        // Deletes the previous transaction log files.
  +        String logFileDir = "txlog";
  +        File[] files = new File(logFileDir).listFiles();
  +        if ( null != files ) {
  +            for (int i = 0; i < files.length; i++) {
  +                files[i].delete();
  +            }
  +        }
           HOWLLog howlLog = new HOWLLog(
                   "org.objectweb.howl.log.BlockLogBuffer", //                "bufferClassName",
                   4, //                "bufferSizeKBytes",
                   true, //                "checksumEnabled",
                   20, //                "flushSleepTime",
  -                "txlog", //                "logFileDir",
  +                logFileDir, //                "logFileDir",
                   "log", //                "logFileExt",
                   LOG_FILE_NAME, //                "logFileName",
                   200, //                "maxBlocksPerFile",
  
  
  

Mime
View raw message