activemq-artemis git commit: ARTEMIS-1531 Fixing checkstyl on byteman test

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

activemq-artemis git commit: ARTEMIS-1531 Fixing checkstyl on byteman test

clebertsuconic-2
Repository: activemq-artemis
Updated Branches:
  refs/heads/master abf104171 -> 09a66fb8d


ARTEMIS-1531 Fixing checkstyl on byteman test


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/09a66fb8
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/09a66fb8
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/09a66fb8

Branch: refs/heads/master
Commit: 09a66fb8d0ae91a8bdf68fcc842edf5bade753f5
Parents: abf1041
Author: Clebert Suconic <[hidden email]>
Authored: Wed Nov 29 18:20:18 2017 -0500
Committer: Clebert Suconic <[hidden email]>
Committed: Wed Nov 29 18:20:18 2017 -0500

----------------------------------------------------------------------
 .../analyzer/FileSystemSyncBlockedTest.java     | 30 ++++++--------------
 1 file changed, 8 insertions(+), 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/09a66fb8/tests/extra-tests/src/test/java/org/apache/activemq/artemis/tests/extras/byteman/critical/analyzer/FileSystemSyncBlockedTest.java
----------------------------------------------------------------------
diff --git a/tests/extra-tests/src/test/java/org/apache/activemq/artemis/tests/extras/byteman/critical/analyzer/FileSystemSyncBlockedTest.java b/tests/extra-tests/src/test/java/org/apache/activemq/artemis/tests/extras/byteman/critical/analyzer/FileSystemSyncBlockedTest.java
index d5cfe49..5506da6 100644
--- a/tests/extra-tests/src/test/java/org/apache/activemq/artemis/tests/extras/byteman/critical/analyzer/FileSystemSyncBlockedTest.java
+++ b/tests/extra-tests/src/test/java/org/apache/activemq/artemis/tests/extras/byteman/critical/analyzer/FileSystemSyncBlockedTest.java
@@ -31,39 +31,25 @@ import org.junit.runner.RunWith;
 @RunWith(BMUnitRunner.class)
 public class FileSystemSyncBlockedTest extends CriticalAnalyzerFaultInjectionTestBase {
 
-   @BMRules(
-      rules = {
-         @BMRule(
-            name = "Simulate Slow Disk Sync",
-            targetClass = "org.apache.activemq.artemis.core.io.nio.NIOSequentialFile",
-            targetMethod = "sync",
-            targetLocation = "ENTRY",
-            condition = "!flagged(\"testSlowDiskSync\")",  // Once the server shutdowns we stop applying this rule.
-            action = "waitFor(\"testSlowDiskSync\")"),
-         @BMRule(
-            // We ensure that no more
-            name = "Release Suspended Thread during Server Shutdown", // Releases wakes up suspended threads to allow shutdown to complete
-            targetClass = "org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl",
-            targetMethod = "stop",
-            targetLocation = "ENTRY",
-            action = "flag(\"testSlowDiskSync\"); signalWake(\"testSlowDiskSync\")")
-      })
+   @BMRules(rules = {@BMRule(name = "Simulate Slow Disk Sync", targetClass = "org.apache.activemq.artemis.core.io.nio.NIOSequentialFile", targetMethod = "sync", targetLocation = "ENTRY", condition = "!flagged(\"testSlowDiskSync\")",  // Once the server shutdowns we stop applying this rule.
+      action = "waitFor(\"testSlowDiskSync\")"), @BMRule(
+      // We ensure that no more
+      name = "Release Suspended Thread during Server Shutdown", // Releases wakes up suspended threads to allow shutdown to complete
+      targetClass = "org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl", targetMethod = "stop", targetLocation = "ENTRY", action = "flag(\"testSlowDiskSync\"); signalWake(\"testSlowDiskSync\")")})
    @Test(timeout = 60000)
-   public void testSlowDiskSync()  throws Exception {
+   public void testSlowDiskSync() throws Exception {
       testSendDurableMessage();
    }
 
    @Test
-   public void testManyFiles() throws Exception
-   {
+   public void testManyFiles() throws Exception {
       Session s = conn.createSession(true, Session.SESSION_TRANSACTED);
 
       Queue jmsQueue = s.createQueue(address.toString());
       MessageProducer p = s.createProducer(jmsQueue);
       p.setDeliveryMode(DeliveryMode.PERSISTENT);
       conn.start();
-      for (int i = 0; i < 1000; i++)
-      {
+      for (int i = 0; i < 1000; i++) {
          p.send(s.createTextMessage("payload"));
          server.getStorageManager().getMessageJournal().forceMoveNextFile();
       }