View Javadoc

    1   package net.sourceforge.pmd.lang.java.rule.migrating;
    2
    3   import net.sourceforge.pmd.testframework.SimpleAggregatorTst;
    4
    5   import org.junit.Before;
    6
    7
    8   public class MigratingRulesTest extends SimpleAggregatorTst {
    9
    10      private static final String RULESET = "java-migrating";
    11
    12      @Before
    13      public void setUp() {
    14          addRule(RULESET, "AvoidAssertAsIdentifier");
    15          addRule(RULESET, "AvoidEnumAsIdentifier");
    16          addRule(RULESET, "ByteInstantiation");
    17          addRule(RULESET, "IntegerInstantiation");
    18          addRule(RULESET, "JUnit4SuitesShouldUseSuiteAnnotation");
    19          addRule(RULESET, "JUnit4TestShouldUseAfterAnnotation");
    20          addRule(RULESET, "JUnit4TestShouldUseBeforeAnnotation");
    21          addRule(RULESET, "JUnit4TestShouldUseTestAnnotation");
    22          addRule(RULESET, "JUnitUseExpected");
    23          addRule(RULESET, "LongInstantiation");
    24          addRule(RULESET, "ReplaceEnumerationWithIterator");
    25          addRule(RULESET, "ReplaceHashtableWithMap");
    26          addRule(RULESET, "ReplaceVectorWithList");
    27          addRule(RULESET, "ShortInstantiation");
    28      }
    29
    30      public static junit.framework.Test suite() {
    31          return new junit.framework.JUnit4TestAdapter(MigratingRulesTest.class);
    32      }
    33  }