1 package test.net.sourceforge.pmd.rules.junit; 2 3 import org.junit.Before; 4 5 import test.net.sourceforge.pmd.testframework.SimpleAggregatorTst; 6 7 public class JunitRulesTest extends SimpleAggregatorTst { 8 9 @Before 10 public void setUp() { 11 addRule("junit", "JUnitAssertionsShouldIncludeMessage"); 12 addRule("junit", "JUnitSpelling"); 13 addRule("junit", "JUnitStaticSuite"); 14 addRule("junit", "JUnitTestsShouldIncludeAssert"); 15 addRule("junit", "SimplifyBooleanAssertion"); 16 addRule("junit", "TestClassWithoutTestCases"); 17 addRule("junit", "UnnecessaryBooleanAssertion"); 18 addRule("junit", "UseAssertEqualsInsteadOfAssertTrue"); 19 addRule("junit", "UseAssertNullInsteadOfAssertTrue"); 20 addRule("junit", "UseAssertSameInsteadOfAssertTrue"); 21 } 22 23 public static junit.framework.Test suite() { 24 return new junit.framework.JUnit4TestAdapter(JunitRulesTest.class); 25 } 26 }