Example #1
0
    def test_set_with_one_annotation(self):
        ci = HPOSet([self.ontology[11], self.ontology[13], self.ontology[31]])

        assert len(ci.all_genes()) == 1
        assert len(ci.omim_diseases()) == 1
        assert len(ci.orpha_diseases()) == 1
        assert len(ci.decipher_diseases()) == 1

        assert ci.all_genes() == set([Gene.get(0)])
        assert ci.omim_diseases() == set([Omim.get(0)])
        assert ci.orpha_diseases() == set([Orpha.get(0)])
        assert ci.decipher_diseases() == set([Decipher.get(0)])
Example #2
0
    def test_set_with_all_annotations(self):
        ci = HPOSet([self.ontology[11], self.ontology[12], self.ontology[41]])

        assert len(ci.all_genes()) == 2
        assert len(ci.omim_diseases()) == 2
        assert len(ci.orpha_diseases()) == 2
        assert len(ci.decipher_diseases()) == 2