mirror of https://github.com/apache/activemq.git
Improve AMQ7118Test stability
This commit is contained in:
parent
12e7a1952b
commit
75c3fd4c34
|
@ -185,12 +185,18 @@ public class AMQ7118Test {
|
|||
if(doCheckpoint) {
|
||||
LOG.info("Initiating checkpointUpdate "+ ++checkpointIndex + " ...");
|
||||
broker.getPersistenceAdapter().checkpoint(true);
|
||||
TimeUnit.SECONDS.sleep(2);
|
||||
TimeUnit.SECONDS.sleep(4);
|
||||
LOG.info("Checkpoint complete.");
|
||||
}
|
||||
File files[] = dbfiles.listFiles(lff);
|
||||
Arrays.sort(files, new DBFileComparator() );
|
||||
logfiles(files);
|
||||
|
||||
while (files.length != expectedCount) {
|
||||
// gives time to checkpoint
|
||||
TimeUnit.SECONDS.sleep(1);
|
||||
}
|
||||
|
||||
assertEquals(expectedCount, files.length);
|
||||
assertEquals(lastFileName, files[files.length-1].getName());
|
||||
|
||||
|
|
Loading…
Reference in New Issue