Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(2)  |  Derive(0)  |  Import(2)

src/c/o/cogent-1.5.3/tests/test_parse/test_blast_xml.py   cogent(Download)
 
from cogent.util.unit_test import main, TestCase
from cogent.parse.blast_xml import BlastXMLResult, MinimalBlastParser7,\
     get_tag, parse_hsp, parse_hit, parse_header, parse_parameters,\
     HSP_XML_FIELDNAMES, HIT_XML_FIELDNAMES
    def test_parse_parameters(self):
        """Fields from XML parameter tag should be available as dict."""
        data = parse_parameters(self.param)
        self.assertEqual(data.get('matrix'), 'BLOSUM62')
        self.assertEqual(data.get('expect'), '10')

src/p/y/pycogent-HEAD/tests/test_parse/test_blast_xml.py   pycogent(Download)
 
from cogent.util.unit_test import main, TestCase
from cogent.parse.blast_xml import BlastXMLResult, MinimalBlastParser7,\
     get_tag, parse_hsp, parse_hit, parse_header, parse_parameters,\
     HSP_XML_FIELDNAMES, HIT_XML_FIELDNAMES
    def test_parse_parameters(self):
        """Fields from XML parameter tag should be available as dict."""
        data = parse_parameters(self.param)
        self.assertEqual(data.get('matrix'), 'BLOSUM62')
        self.assertEqual(data.get('expect'), '10')