sq.addPDBId(new PDBEntry("2PDB", "A", Type.MMCIF, "filePath/test2"));
sq.addPDBId(new PDBEntry("2PDB", "B", Type.MMCIF, "filePath/test2"));
+ // these are the same as ones already added
DBRefEntry pdb1pdb = new DBRefEntry("PDB", "version1", "1PDB");
- DBRefEntry pdb2pdb = new DBRefEntry("PDB", "version1", "2PDB");
+ DBRefEntry pdb2pdb = new DBRefEntry("PDB", "version2", "2PDB");
List<DBRefEntry> primRefs = Arrays.asList(new DBRefEntry[] { pdb1pdb,
pdb2pdb });
- sq.getDatasetSequence().addDBRef(pdb1pdb);
- sq.getDatasetSequence().addDBRef(pdb2pdb);
+ sq.getDatasetSequence().addDBRef(pdb1pdb); // should do nothing
+ sq.getDatasetSequence().addDBRef(pdb2pdb); // should do nothing
sq.getDatasetSequence().addDBRef(
- new DBRefEntry("PDB", "version3", "3PDB"));
+ new DBRefEntry("PDB", "version3", "3PDB")); // should do nothing
sq.getDatasetSequence().addDBRef(
- new DBRefEntry("PDB", "version4", "4PDB"));
+ new DBRefEntry("PDB", "version4", "4PDB")); // should do nothing
PDBEntry pdbe1a=new PDBEntry("1PDB", "A", Type.PDB, "filePath/test1");
PDBEntry pdbe1b = new PDBEntry("1PDB", "B", Type.PDB, "filePath/test1");
new AlignmentAnnotation("Test annot", "Test annot description",
annots));
Assert.assertEquals(sq.getDescription(), "Test sequence description..");
- Assert.assertEquals(sq.getDBRefs().length, 5);
+ Assert.assertEquals(sq.getDBRefs().length, 5); // DBRefs are on dataset
+ // sequence
Assert.assertEquals(sq.getAllPDBEntries().size(), 4);
Assert.assertNotNull(sq.getAnnotation());
Assert.assertEquals(sq.getAnnotation()[0].annotations.length, 2);
- Assert.assertEquals(sq.getDatasetSequence().getDBRefs().length, 4);
+ Assert.assertEquals(sq.getDatasetSequence().getDBRefs().length, 5); // same
+ // as
+ // sq.getDBRefs()
Assert.assertEquals(sq.getDatasetSequence().getAllPDBEntries().size(),
4);
Assert.assertNotNull(sq.getDatasetSequence().getAnnotation());
Assert.assertEquals(derived.getDescription(),
"Test sequence description..");
- Assert.assertEquals(derived.getDBRefs().length, 4); // come from dataset
+ Assert.assertEquals(derived.getDBRefs().length, 5); // come from dataset
Assert.assertEquals(derived.getAllPDBEntries().size(), 4);
Assert.assertNotNull(derived.getAnnotation());
Assert.assertEquals(derived.getAnnotation()[0].annotations.length, 2);
- Assert.assertEquals(derived.getDatasetSequence().getDBRefs().length, 4);
+ Assert.assertEquals(derived.getDatasetSequence().getDBRefs().length, 5);
Assert.assertEquals(derived.getDatasetSequence().getAllPDBEntries()
.size(), 4);
Assert.assertNotNull(derived.getDatasetSequence().getAnnotation());