use of net.sourceforge.pmd.FooRule in project pmd by pmd.
the class SuppressWarningsTest method testConstructorLevelSuppression.
@Test
public void testConstructorLevelSuppression() {
Report rpt = new Report();
runTestFromString(TEST5, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(0, rpt.size());
}
use of net.sourceforge.pmd.FooRule in project pmd by pmd.
the class SuppressWarningsTest method testClassLevelSuppression.
@Test
public void testClassLevelSuppression() {
Report rpt = new Report();
runTestFromString(TEST1, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(0, rpt.size());
runTestFromString(TEST2, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(0, rpt.size());
}
use of net.sourceforge.pmd.FooRule in project pmd by pmd.
the class SuppressWarningsTest method testNoSuppressionBlank.
@Test
public void testNoSuppressionBlank() {
Report rpt = new Report();
runTestFromString(TEST10, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(2, rpt.size());
}
use of net.sourceforge.pmd.FooRule in project pmd by pmd.
the class SuppressWarningsTest method testParameterLevelSuppression.
@Test
public void testParameterLevelSuppression() {
Report rpt = new Report();
runTestFromString(TEST7, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(1, rpt.size());
}
use of net.sourceforge.pmd.FooRule in project pmd by pmd.
the class SuppressWarningsTest method testSpecificSuppressionValue1.
@Test
public void testSpecificSuppressionValue1() {
Report rpt = new Report();
runTestFromString(TEST9_VALUE1, new FooRule(), rpt, LanguageRegistry.getLanguage(JavaLanguageModule.NAME).getVersion("1.5"));
assertEquals(1, rpt.size());
}
Aggregations