コード例 #1
0
ファイル: test_alt_ids.py プロジェクト: shunsunsun/pyobo
 def test_already_primary(self, _, __):
     """Test when you give a primary id."""
     primary_id = get_primary_identifier('go', '0003700')
     self.assertIsNotNone(primary_id)
     self.assertEqual('0003700', primary_id)
     name = get_name('go', '0003700')
     self.assertIsNotNone(name)
     self.assertEqual('DNA-binding transcription factor activity', name)
コード例 #2
0
ファイル: test_alt_ids.py プロジェクト: shunsunsun/pyobo
 def test_get_primary(self, _, __):
     """Test upgrading an obsolete identifier."""
     primary_id = get_primary_identifier('go', '0001071')
     self.assertIsNotNone(primary_id)
     self.assertEqual('0003700', primary_id)
     name = get_name('go', '0001071')
     self.assertIsNotNone(name)
     self.assertEqual('DNA-binding transcription factor activity', name)
コード例 #3
0
 def test_already_primary(self, _, __):
     """Test when you give a primary id."""
     primary_id = get_primary_identifier("go", "0003700")
     self.assertIsNotNone(primary_id)
     self.assertEqual("0003700", primary_id)
     name = get_name("go", "0003700")
     self.assertIsNotNone(name)
     self.assertEqual("DNA-binding transcription factor activity", name)
コード例 #4
0
 def test_get_primary(self, _, __):
     """Test upgrading an obsolete identifier."""
     primary_id = get_primary_identifier("go", "0001071")
     self.assertIsNotNone(primary_id)
     self.assertEqual("0003700", primary_id)
     name = get_name("go", "0001071")
     self.assertIsNotNone(name)
     self.assertEqual("DNA-binding transcription factor activity", name)
コード例 #5
0
ファイル: test_alt_ids.py プロジェクト: shunsunsun/pyobo
 def test_no_alts(self, _, __):
     """Test alternate behavior for nomenclature source with no alts."""
     primary_id = get_primary_identifier('ncbitaxon', '52818')
     self.assertEqual('52818', primary_id)
     self.assertEqual('Allamanda cathartica', get_name('ncbitaxon', '52818'))
コード例 #6
0
 def test_no_alts(self, _, __):
     """Test alternate behavior for nomenclature source with no alts."""
     primary_id = get_primary_identifier("ncbitaxon", "52818")
     self.assertEqual("52818", primary_id)
     self.assertEqual("Allamanda cathartica",
                      get_name("ncbitaxon", "52818"))