public void testReadIUPredForShortAndLongDisorder() {\r
try {\r
Map<String, Score> scores = SequenceUtil.readIUPred(new File(\r
- AllTestSuit.TEST_DATA_PATH, "output.long"),\r
- IUPredResult.Long);\r
+ AllTestSuit.TEST_DATA_PATH, "output.long"));\r
ScoreManager man = ScoreManager.newInstanceSingleScore(scores);\r
- man.writeOut(new PrintWriter(System.out, true));\r
+ // man.writeOut(new PrintWriter(System.out, true));\r
+ assertNotNull(scores);\r
+ assertEquals(2, scores.size());\r
+\r
+ Score score = scores.get("P50_HUMAN");\r
+ assertNotNull(score);\r
+ assertEquals(0, score.getRanges().size());\r
+ assertEquals(393, score.getScores().size());\r
+ assertEquals("Long", score.getMethod());\r
} catch (IOException e) {\r
e.printStackTrace();\r
fail(e.getLocalizedMessage());\r
public void testReadIUPredForGlobDomain() {\r
try {\r
Map<String, Score> scores = SequenceUtil.readIUPred(new File(\r
- AllTestSuit.TEST_DATA_PATH, "output.glob"),\r
- IUPredResult.Glob);\r
+ AllTestSuit.TEST_DATA_PATH, "output.glob"));\r
+ assertNotNull(scores);\r
+ assertEquals(2, scores.size());\r
ScoreManager man = ScoreManager.newInstanceSingleScore(scores);\r
- man.writeOut(new PrintWriter(System.out, true));\r
+ // man.writeOut(new PrintWriter(System.out, true));\r
+ assertEquals(2, man.getNumberOfSeq());\r
+ Score score = scores.get("P53_HUMA");\r
+ assertNotNull(score);\r
+ assertEquals(2, score.getRanges().size());\r
+ assertEquals(0, score.getScores().size());\r
+ assertEquals("Glob", score.getMethod());\r
+\r
+ score = scores.get("Foobar_dundeefriends");\r
+ assertEquals(0, score.getRanges().size());\r
} catch (IOException e) {\r
e.printStackTrace();\r
fail(e.getLocalizedMessage());\r
fail(e.getLocalizedMessage());\r
}\r
}\r
-\r
@Test\r
public void testReadAAConResults() {\r
try {\r