标签:create 单元 new 注意 ott record tor package run
package com.test.service;
import com.task.Application;
import com.task.model.po.TaskRecordDo;
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;
/**
* Created by admin on 2017/9/21-11:33.
* Description :
*/
@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest(classes = Application.class)
public class TaskRecordServiceTest {
@Autowired
private TaskRecordService taskRecordService;
@Test
public void insertTest(){
TaskRecordDo taskRecordDo = new TaskRecordDo("8654111110001", "11110001", "adminTask", "UUIDTest", "修改生产服设备ID", "200");
taskRecordService.insertTaskRecord(taskRecordDo);
}
}
*注意 一个简单的测试单元就这样成功了
标签:create 单元 new 注意 ott record tor package run
原文地址:http://www.cnblogs.com/xubiao/p/7568257.html