springboot service测试

springboot 项目的测试方法
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;


import com.wind.activiti.Server.ExampleService;


@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest(classes = AbcApplication.class)
public class TestExampleService {
    
    @Autowired
    ExampleService exampleService;
    
    @Test
    public void inverstor() {
        
        exampleService.call("add", ls, "", "");
    }
}

发布了36 篇原创文章 · 获赞 5 · 访问量 4万+

猜你喜欢

转载自blog.csdn.net/eyugod/article/details/77678853
今日推荐