Skip to content

Commit

Permalink
*** empty log message ***
Browse files Browse the repository at this point in the history
  • Loading branch information
katel committed Jul 4, 2000
1 parent eeca676 commit e542a63
Showing 1 changed file with 56 additions and 0 deletions.
56 changes: 56 additions & 0 deletions Tests/test_prosite2.py
@@ -0,0 +1,56 @@
# Copyright 1999 by Jeffrey Chang. All rights reserved.
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.

import os
from types import *
from Bio import File
from Bio import ParserSupport
from Bio.Prosite import Prosite


tests = [ 'ps00107.txt', 'ps00159.txt', 'ps00165.txt', 'ps00213.txt', 'ps00432.txt', \
'ps00488.txt', 'ps00546.txt' ]
record_parser = Prosite.RecordParser()

def print_list( list ):
for item in list:
print( ' ' + str( item ) )

for test in tests:
print "testing %s" % test
datafile = os.path.join( 'Prosite', test )
src_handle = open( datafile )
data = record_parser.parse( src_handle )
print data.name
print data.type
print data.accession
print data.created
print data.data_update
# print data.data_info
print data.pdoc
print data.description
print data.pattern
print data.matrix
print data.rules
print data.nr_sp_release
print data.nr_sp_seqs
print data.cc_taxo_range
print data.cc_max_repeat
# print data.name
print 'cc_site'
print_list( data.cc_site )
print 'dr_positive'
print_list( data.dr_positive )
print 'dr_false_neg'
print_list( data.dr_false_neg )
print 'dr_false_pos'
print_list( data.dr_false_pos )
print 'dr_potential'
print_list( data.dr_potential )
print 'dr_unknown'
print_list( data.dr_unknown )
print 'pdb_structs'
print_list( data.pdb_structs )

0 comments on commit e542a63

Please sign in to comment.