Package com.puppycrawl.tools.checkstyle

Examples of com.puppycrawl.tools.checkstyle.DefaultConfiguration


    }

    @Test
    public void testTypeParameters() throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocTypeCheck.class);
        final String[] expected = {
            "7:4: Unused @param tag for '<D123>'.",
            "11: Type Javadoc comment is missing an @param <C456> tag.",
        };
View Full Code Here


        verify(checkConfig, getPath("InputTypeParamsTags.java"), expected);
    }
    @Test
    public void testAllowMissingTypeParameters() throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocTypeCheck.class);
        checkConfig.addAttribute("allowMissingParamTags", "true");
        final String[] expected = {
            "7:4: Unused @param tag for '<D123>'.",
        };
        verify(checkConfig, getPath("InputTypeParamsTags.java"), expected);
    }
View Full Code Here

    }

    @Test
    public void testBadTag() throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocTypeCheck.class);
        final String[] expected = {
            "5:4: Unknown tag 'mytag'.",
        };
        verify(checkConfig,
View Full Code Here

    }

    @Test
    public void testBadTagSuppress() throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocTypeCheck.class);
        checkConfig.addAttribute("allowUnknownTags", "true");
        final String[] expected = {
        };
        verify(checkConfig,
               getPath("javadoc" + File.separator + "InputBadTag.java"),
               expected);
View Full Code Here

{
    @Test
    public void testDefault()
        throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        final String[] expected = {
            "11:5: Missing a Javadoc comment.",
            "304:5: Missing a Javadoc comment.",
            "311:5: Missing a Javadoc comment.",
View Full Code Here

    @Test
    public void testAnother()
        throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        final String[] expected = {
            "17:9: Missing a Javadoc comment.",
            "24:9: Missing a Javadoc comment.",
            "30:13: Missing a Javadoc comment.",
View Full Code Here

    @Test
    public void testAnother2()
        throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        checkConfig.addAttribute("scope", Scope.PUBLIC.getName());
        final String[] expected = {
        };
        verify(checkConfig, getPath("InputInner.java"), expected);
    }
View Full Code Here

    @Test
    public void testAnother3()
        throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        final String[] expected = {
            "11:9: Missing a Javadoc comment.",
            "16:13: Missing a Javadoc comment.",
            "36:9: Missing a Javadoc comment.",
View Full Code Here

    }
    @Test
    public void testAnother4()
        throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        checkConfig.addAttribute("scope", Scope.PUBLIC.getName());
        final String[] expected = {
            "46:5: Missing a Javadoc comment.",
        };
        verify(checkConfig, getPath("InputPublicOnly.java"), expected);
    }
View Full Code Here

    }

    @Test
    public void testScopes() throws Exception
    {
        final DefaultConfiguration checkConfig =
            createCheckConfig(JavadocVariableCheck.class);
        final String[] expected = {
            "5:5: Missing a Javadoc comment.",
            "6:5: Missing a Javadoc comment.",
            "7:5: Missing a Javadoc comment.",
View Full Code Here

TOP

Related Classes of com.puppycrawl.tools.checkstyle.DefaultConfiguration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.