コード例 #1
0
 @Test
 public void testRemove() throws Exception {
   experimentResource.remove(ResourceType.PROCESS, processId);
   assertFalse(
       "process data removed successfully",
       processResource.isExists(ResourceType.PROCESS, processId));
 }
コード例 #2
0
  @Before
  public void setUp() throws Exception {
    super.setUp();
    Timestamp creationTime = new Timestamp(new Date().getTime());

    experimentResource = (ExperimentResource) getGatewayResource().create(ResourceType.EXPERIMENT);
    experimentResource.setExperimentId(experimentID);
    experimentResource.setExperimentName(experimentID);
    experimentResource.setUserName(getWorkerResource().getUser());
    experimentResource.setProjectId(getProjectResource().getId());
    experimentResource.setCreationTime(creationTime);
    experimentResource.save();

    processResource = (ProcessResource) experimentResource.create(ResourceType.PROCESS);
    processResource.setProcessId(processId);
    processResource.setExperimentId(experimentID);
    processResource.setCreationTime(creationTime);
    processResource.save();
  }