Skip to content

Commit 66cfcdc

Browse files
committed
biojava#308 adding a test that demonstrates that fetching mmCIF files from remote URLs is broken. Also tests for correct parsing of compressed files.
1 parent 7cd7100 commit 66cfcdc

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
package org.biojava.nbio.structure.io;
2+
3+
import junit.framework.TestCase;
4+
import org.biojava.nbio.structure.Structure;
5+
import org.biojava.nbio.structure.StructureException;
6+
import org.biojava.nbio.structure.StructureIO;
7+
import org.junit.Test;
8+
9+
import java.io.IOException;
10+
11+
/**
12+
* Created by ap3 on 31/07/2015.
13+
*/
14+
public class TestURLBasedFileParsing extends TestCase{
15+
16+
@Test
17+
public void testMMcifURL(){
18+
19+
String u = "http://ftp.wwpdb.org/pub/pdb/data/biounit/mmCIF/divided/nw/4nwr-assembly1.cif.gz";
20+
21+
try {
22+
Structure s = StructureIO.getStructure(u);
23+
24+
System.out.println(s);
25+
} catch (Exception e) {
26+
e.printStackTrace();
27+
}
28+
29+
30+
}
31+
}

0 commit comments

Comments
 (0)