Esempio n. 1
0
    def test_exception(self):
        peptide = MockPeptide()
        pg = peakgroup.MinimalPeakGroup("f_1", 0.1, 100, False, -1, peptide)

        self.assertRaises(Exception, pg.set_fdr_score, 4)
        self.assertRaises(Exception, pg.set_normalized_retentiontime, 4)
        self.assertRaises(Exception, pg.set_feature_id, 4)
        self.assertRaises(Exception, pg.set_intensity, 4)
Esempio n. 2
0
 def test_setClusterId(self):
     peptide = MockPeptide()
     pg = peakgroup.MinimalPeakGroup("f_1", 0.1, 100, False, -1, peptide)
     pg.setClusterID(5)
     self.assertEqual(pg.get_cluster_id(), 5)
Esempio n. 3
0
 def test_create_pg(self):
     pg = peakgroup.MinimalPeakGroup("f_1", 0.1, 100, False, -1, None)
     self.assertTrue(True)
Esempio n. 4
0
 def test_dscore(self):
     peptide = MockPeptide()
     pg = peakgroup.MinimalPeakGroup("f_1", 0.1, 100, False, -1, peptide,
                                     None, 42)
     self.assertAlmostEqual(pg.get_dscore(), 42)