The following issues were found

src/test/java/com/alibaba/json/bvt/NotWriteRootClassNameTest.java
1 issues
JUnit 4 tests that execute tests should use the @Test annotation, JUnit 5 tests should use @Test, @RepeatedTest, @TestFactory, @TestTemplate or @ParameterizedTest
Design

Line: 11

              

public class NotWriteRootClassNameTest extends TestCase {
    public void test_NotWriteRootClassName() throws Exception {
        SerializerFeature[] features = new SerializerFeature[] {SerializerFeature.WriteClassName, SerializerFeature.NotWriteRootClassName};
        Assert.assertEquals("{}", JSON.toJSONString(new VO(), features));
        Assert.assertEquals("{}", JSON.toJSONString(new V1(), features));
    }
    

            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3796/bean/ObjectF2.java
1 issues
The class 'ObjectF2' is suspected to be a Data Class (WOC=0.000%, NOPA=0, NOAM=8, WMC=8)
Design

Line: 6

              import java.util.List;


public class ObjectF2 {

	
	private int a;

	

            

Reported by PMD.

src/test/java/com/alibaba/json/bvt/MapTest2.java
1 issues
JUnit 4 tests that execute tests should use the @Test annotation, JUnit 5 tests should use @Test, @RepeatedTest, @TestFactory, @TestTemplate or @ParameterizedTest
Design

Line: 13

              

public class MapTest2 extends TestCase {
    public void test_map () throws Exception {
Map<Object, Object> map = JSON.parseObject("{1:\"2\",\"3\":4,'5':6}", new TypeReference<Map<Object, Object>>() {});
Assert.assertEquals("2", map.get(1));
Assert.assertEquals(4, map.get("3"));
Assert.assertEquals(6, map.get("5"));
    }

            

Reported by PMD.

src/main/java/com/alibaba/fastjson/support/hsf/MethodLocator.java
1 issues
Consider using varargs for methods or constructors which take an array the last parameter.
Design

Line: 6

              import java.lang.reflect.Method;

public interface MethodLocator {
    Method findMethod(String[] types);
}

            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3796/bean/CommonObject.java
1 issues
The class 'CommonObject' is suspected to be a Data Class (WOC=0.000%, NOPA=0, NOAM=6, WMC=8)
Design

Line: 4

              package com.alibaba.fastjson.deserializer.issues3796.bean;


public class CommonObject {

	private int a;

	private int b;


            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3796/bean/ObjectM1_A.java
1 issues
The class 'ObjectM1_A' is suspected to be a Data Class (WOC=0.000%, NOPA=0, NOAM=4, WMC=4)
Design

Line: 7

              


public class ObjectM1_A {
    
    private int a;
    
    private int b;


            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3796/TestIssues3796.java
1 issues
JUnit tests should include assert() or fail()
Design

Line: 15

              public class TestIssues3796 {

    @Test
    public void testIssues3796() {
        JSON.parseObject("{}", LargeJavaBean.class);
    }
}

            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3671/TestIssue3671.java
1 issues
Potential violation of Law of Demeter (method chain calls)
Design

Line: 29

                              "    }],\n" +
                "    \"uri\": \"https://www.baidu.com\"\n" +
                "}]\n ";
        Assert.assertTrue(JSONValidator.from(json).validate());
    }

}

            

Reported by PMD.

src/test/java/com/alibaba/fastjson/deserializer/issues3796/bean/ObjectU1_A.java
1 issues
The class 'ObjectU1_A' is suspected to be a Data Class (WOC=0.000%, NOPA=0, NOAM=6, WMC=6)
Design

Line: 7

              


public class ObjectU1_A {
	
	private int a;
	
	private long b;
	

            

Reported by PMD.

src/test/java/com/alibaba/json/bvt/MapTest.java
1 issues
JUnit 4 tests that execute tests should use the @Test annotation, JUnit 5 tests should use @Test, @RepeatedTest, @TestFactory, @TestTemplate or @ParameterizedTest
Design

Line: 13

              
public class MapTest extends TestCase {

    public void test_null() throws Exception {
        Map<String, Object> map = new HashMap<String, Object>();
        map.put(null, "123");
        String text = JSON.toJSONString(map);
        Assert.assertEquals("{null:\"123\"}", text);
    }

            

Reported by PMD.