Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
c02f035623
|
@ -16,7 +16,6 @@ public class MetaSensorItem {
|
|||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
|
|
@ -14,6 +14,13 @@ public class MetaSensorItemType {
|
|||
private String description;
|
||||
private Date createDate;
|
||||
|
||||
public MetaSensorItemType() {
|
||||
}
|
||||
|
||||
public MetaSensorItemType(short id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Id
|
||||
public short getId() {
|
||||
return id;
|
||||
|
|
|
@ -19,4 +19,12 @@ public class MetaSensorItemTypeService {
|
|||
public List<MetaSensorItemType> readAll() {
|
||||
return this.sensorItemTypeDAO.findAll();
|
||||
}
|
||||
|
||||
public MetaSensorItemType regist(MetaSensorItemType type){
|
||||
return this.sensorItemTypeDAO.save(type);
|
||||
}
|
||||
|
||||
public List<MetaSensorItemType> registAll(List<MetaSensorItemType> list) {
|
||||
return this.sensorItemTypeDAO.save(list);
|
||||
}
|
||||
}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -11,8 +11,6 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* Created by snoop on 17. 7. 27.
|
||||
*/
|
||||
|
@ -32,4 +30,5 @@ public class MetaSensorItemServiceTest {
|
|||
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -3,6 +3,7 @@ package com.loafle.overflow.module.meta.service;
|
|||
import com.loafle.overflow.module.meta.model.MetaSensorItemType;
|
||||
import com.loafle.overflow.spring.AppConfigTest;
|
||||
import org.junit.Assert;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
@ -11,8 +12,6 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
/**
|
||||
* Created by snoop on 17. 7. 27.
|
||||
*/
|
||||
|
@ -24,6 +23,7 @@ public class MetaSensorItemTypeServiceTest {
|
|||
private MetaSensorItemTypeService sensorItemTypeService;
|
||||
|
||||
@Test
|
||||
@Ignore
|
||||
public void readAll() throws Exception {
|
||||
List<MetaSensorItemType> metaSensorItemTypes = this.sensorItemTypeService.readAll();
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@ package com.loafle.overflow.module.meta.service;
|
|||
|
||||
import com.loafle.overflow.module.meta.model.MetaSensorItemUnit;
|
||||
import com.loafle.overflow.spring.AppConfigTest;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
@ -19,7 +20,16 @@ public class MetaSensorItemUnitServiceTest {
|
|||
private MetaSensorItemUnitService service;
|
||||
|
||||
@Test
|
||||
@Ignore
|
||||
public void regist() throws Exception {
|
||||
|
||||
MetaSensorItemUnit defaultValue = new MetaSensorItemUnit();
|
||||
defaultValue.setId((short)0);
|
||||
defaultValue.setUnit("");
|
||||
defaultValue.setMark("");
|
||||
this.service.regist(defaultValue);
|
||||
|
||||
|
||||
MetaSensorItemUnit unit1 = new MetaSensorItemUnit();
|
||||
unit1.setId((short)1);
|
||||
unit1.setUnit("Percentage");
|
||||
|
|
Loading…
Reference in New Issue
Block a user