commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1154433 - /commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java
Date Sat, 06 Aug 2011 02:35:52 GMT
Author: ggregory
Date: Sat Aug  6 02:35:52 2011
New Revision: 1154433

URL: http://svn.apache.org/viewvc?rev=1154433&view=rev
Log:
Sort methods AB.

Modified:
    commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java

Modified: commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java
URL: http://svn.apache.org/viewvc/commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java?rev=1154433&r1=1154432&r2=1154433&view=diff
==============================================================================
--- commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java
(original)
+++ commons/proper/codec/trunk/src/test/org/apache/commons/codec/language/bm/RuleTest.java
Sat Aug  6 02:35:52 2011
@@ -31,6 +31,16 @@ import org.junit.Test;
  * @since 2.0
  */
 public class RuleTest {
+    private static class NegativeIntegerBaseMatcher extends BaseMatcher<Integer> {
+        public void describeTo(Description description) {
+            description.appendText("value should be negative");
+        }
+
+        public boolean matches(Object item) {
+            return ((Integer) item) < 0;
+        }
+    }
+
     private Rule.Phoneme[][] makePhonemes() {
         String[][] words = {
                 { "rinD", "rinDlt", "rina", "rinalt", "rino", "rinolt", "rinu", "rinult"
},
@@ -49,15 +59,6 @@ public class RuleTest {
     }
 
     @Test
-    public void phonemeComparedToSelfIsZero() {
-        for (Rule.Phoneme[] phs : makePhonemes()) {
-            for (Rule.Phoneme ph : phs) {
-                assertEquals("Phoneme compared to itself should be zero: " + ph.getPhonemeText(),
0, ph.compareTo(ph));
-            }
-        }
-    }
-
-    @Test
     public void phonemeComparedToLaterIsNegative() {
         for (Rule.Phoneme[] phs : makePhonemes()) {
             for (int i = 0; i < phs.length; i++) {
@@ -71,13 +72,12 @@ public class RuleTest {
         }
     }
 
-    private static class NegativeIntegerBaseMatcher extends BaseMatcher<Integer> {
-        public boolean matches(Object item) {
-            return ((Integer) item) < 0;
-        }
-
-        public void describeTo(Description description) {
-            description.appendText("value should be negative");
+    @Test
+    public void phonemeComparedToSelfIsZero() {
+        for (Rule.Phoneme[] phs : makePhonemes()) {
+            for (Rule.Phoneme ph : phs) {
+                assertEquals("Phoneme compared to itself should be zero: " + ph.getPhonemeText(),
0, ph.compareTo(ph));
+            }
         }
     }
 }



Mime
View raw message