use of uk.ac.bbsrc.tgac.miso.core.data.TissueOrigin in project miso-lims by miso-lims.
the class OicrLibraryAliasValidatorTest method makeTissueOrigins.
private static List<TissueOrigin> makeTissueOrigins() {
return makeList(new String[] { "Br", "Ly", "Pa" }, alias -> {
TissueOrigin o = new TissueOriginImpl();
o.setAlias(alias);
return o;
});
}
use of uk.ac.bbsrc.tgac.miso.core.data.TissueOrigin in project miso-lims by miso-lims.
the class HibernateTissueOriginDaoIT method getCreateItem.
@Override
public TissueOrigin getCreateItem() {
TissueOrigin origin = new TissueOriginImpl();
origin.setAlias("TO");
origin.setDescription("Test Origin");
User user = (User) currentSession().get(UserImpl.class, 1L);
origin.setChangeDetails(user);
return origin;
}
use of uk.ac.bbsrc.tgac.miso.core.data.TissueOrigin in project miso-lims by miso-lims.
the class HibernateTissueOriginDaoIT method testGetUsage.
@Test
public void testGetUsage() throws Exception {
TissueOrigin origin1 = (TissueOrigin) currentSession().get(TissueOriginImpl.class, 1L);
assertEquals(5, getTestSubject().getUsage(origin1));
TissueOrigin origin2 = (TissueOrigin) currentSession().get(TissueOriginImpl.class, 2L);
assertEquals(0, getTestSubject().getUsage(origin2));
}
Aggregations