File: test_geo.py

package info (click to toggle)
python-biopython 1.45-3
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 18,192 kB
  • ctags: 12,310
  • sloc: python: 83,505; xml: 13,834; ansic: 7,015; cpp: 1,855; sql: 1,144; makefile: 179
file content (30 lines) | stat: -rw-r--r-- 772 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
"""Tests the basic functionality of the GEO parsers.
"""

import os

import Bio.Geo

testfiles   = [  'GSE16.txt', 'GSM645.txt', 'GSM691.txt', 'GSM700.txt', 'GSM804.txt'  ]

#Five additional files from the NCBI to document the GEO SOFT file format
#changes made in 2005.  Note the new table_begin and table_end lines.
testfiles.extend(['soft_ex_affy.txt',
                  'soft_ex_affy_chp.txt',
                  'soft_ex_dual.txt',
                  'soft_ex_family.txt',
                  'soft_ex_platform.txt',
                  'soft_ex_series.txt'])

for file in testfiles:
    fh = open(os.path.join("Geo", file))
    print "Testing Bio.Geo on " + file + "\n\n"
    records = Bio.Geo.parse(fh)
    for record in records:
        print record
    print "\n"