Skip to content

Commit

Permalink
address review comment
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmadshadab committed Nov 21, 2023
1 parent 1d1100e commit 3361090
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

import org.uniprot.core.Statistics;
import org.uniprot.core.cv.xdb.CrossRefEntry;
import org.uniprot.core.util.Utils;

public class CrossRefEntryImpl implements CrossRefEntry {

Expand Down Expand Up @@ -42,7 +43,7 @@ public CrossRefEntryImpl(
this.pubMedId = pubMedId;
this.doiId = doiId;
this.linkType = linkType;
this.servers = servers;
this.servers = Utils.unmodifiableList(servers);
this.dbUrl = dbUrl;
this.category = category;
this.statistics = statistics;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,13 @@ void canAdd_servers() {
assertEquals(List.of(server), obj.getServers());
}

@Test
void canSet_Empty_Servers() {
CrossRefEntry obj = new CrossRefEntryBuilder().serversSet(null).build();
assertNotNull(obj.getServers());
assertTrue(obj.getServers().isEmpty());
}

@Test
void canSet_dbUrl() {
String dbUrl = "dbUrl";
Expand Down

0 comments on commit 3361090

Please sign in to comment.