Skip to content

Commit 699c886

Browse files
committed
1) Updated the mmtf test data to v0.2.0
2) Updated the mmtf structure reader to use the given single letter code 3) mmCIF tests use mmCIF atom cache.
1 parent 6b9c547 commit 699c886

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

biojava-structure/src/main/java/org/biojava/nbio/structure/io/mmtf/MmtfStructureReader.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ public void setGroupInfo(String groupName, int groupNumber,
186186
case 1:
187187
AminoAcid aa = new AminoAcidImpl();
188188
// Now set the one letter code
189-
aa.setAminoType(StructureTools.get1LetterCodeAmino(groupName));
189+
aa.setAminoType(singleLetterCode);
190190
group = aa;
191191
break;
192192
case 2:

biojava-structure/src/test/java/org/biojava/nbio/structure/io/TestParseMmCIFFeatures.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,12 @@ private void assertDisulfideBond(String expectedChainId1, String expectedChainId
142142

143143
@Test
144144
public void testSites()throws IOException, StructureException {
145+
146+
AtomCache cache = new AtomCache();
147+
148+
StructureIO.setAtomCache(cache);
149+
150+
cache.setUseMmCif(true);
145151
Structure sCif = StructureIO.getStructure("4HHB");
146152

147153
assertNotNull(sCif);
@@ -171,6 +177,11 @@ public void testSites()throws IOException, StructureException {
171177

172178
@Test
173179
public void testSites1a4w()throws IOException, StructureException {
180+
AtomCache cache = new AtomCache();
181+
182+
StructureIO.setAtomCache(cache);
183+
184+
cache.setUseMmCif(true);
174185
Structure sCif = StructureIO.getStructure("1A4W");
175186

176187
assertNotNull(sCif);
Binary file not shown.

0 commit comments

Comments
 (0)