package chanedi.generator;

import org.junit.Test;
import org.springframework.core.io.ResourceLoader;
import org.springframework.core.io.support.PathMatchingResourcePatternResolver;

/**
 * Created by jijingyu625 on 2016/4/18.
 */
public class CodeGeneratorTest {

    private ResourceLoader resourceLoader = new PathMatchingResourcePatternResolver();

    @Test
    public void generateSetter() throws Exception {
        CodeGenerator.generateSetter(resourceLoader.getResource("classpath:/source/setterSource").getFile(), "XXXDTO");
    }

    @Test
    public void generateDAOGetMethod() throws Exception {
        CodeGenerator.generateDaoGetMethod(false, "BUS_XX", "com.xx.dto.XXDTO", "String userId, String test");
    }
}
@@ -522,11 +522,19 @@
 ), %22
-XXX
+FundAccount
 DTO%22
@@ -666,64 +666,51 @@
 e, %22
-BUS_XX%22, %22com.xx.dto.XXDTO%22, %22String userId, String test
+ER_FUND_PRODUCTS%22, %22String thirdCompanyCode
 %22);%0A
@@ -716,8 +716,9 @@
 %0A    %7D%0A%7D
+%0A

Update CodeGeneratorTest.java