Skip to content

Commit

Permalink
add tests for link classes
Browse files Browse the repository at this point in the history
  • Loading branch information
Dert1129 committed Nov 11, 2024
1 parent 8cc3539 commit aa664b3
Show file tree
Hide file tree
Showing 2 changed files with 74 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
package org.kpmp.spatialViewerDataset;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertEquals;
public class SpatialViewerExternalLinkIdTest {

private SpatialViewerExternalLinkId spatialViewerExternalLinkId;
@BeforeEach
public void setUp() throws Exception {
spatialViewerExternalLinkId = new SpatialViewerExternalLinkId();
}

@AfterEach
public void tearDown() throws Exception {
spatialViewerExternalLinkId = null;
}

@Test
public void setDlFileId() {
spatialViewerExternalLinkId.setDlFileId("abc_123");
assertEquals("abc_123", spatialViewerExternalLinkId.getDlFileId());
}

@Test
public void setRedcapId() {
spatialViewerExternalLinkId.setRedcapId("redcap_id");
assertEquals("redcap_id", spatialViewerExternalLinkId.getRedcapId());
}

@Test
public void setExperimentalStrategy() {
spatialViewerExternalLinkId.setExperimentalStrategy("stuff");
assertEquals("stuff", spatialViewerExternalLinkId.getExperimentalStrategy());
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
package org.kpmp.spatialViewerDataset;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertEquals;
public class SpatialViewerFileDatsetIdTest {

private SpatialViewerFileDatasetId spatialViewerFileDatasetId;
@BeforeEach
public void setUp() throws Exception {
spatialViewerFileDatasetId = new SpatialViewerFileDatasetId();
}

@AfterEach
public void tearDown() throws Exception {
spatialViewerFileDatasetId = null;
}

@Test
public void setDlFileId() {
spatialViewerFileDatasetId.setDlFileId("abc_123");
assertEquals("abc_123", spatialViewerFileDatasetId.getDlFileId());
}

@Test
public void setRedcapId() {
spatialViewerFileDatasetId.setRedcapId("redcap_id");
assertEquals("redcap_id", spatialViewerFileDatasetId.getRedcapId());
}

@Test
public void setExperimentalStrategy() {
spatialViewerFileDatasetId.setExperimentalStrategy("stuff");
assertEquals("stuff", spatialViewerFileDatasetId.getExperimentalStrategy());
}
}

0 comments on commit aa664b3

Please sign in to comment.