1 | import os, unittest, random |
---|
2 | |
---|
3 | import testlib |
---|
4 | from genetrack import conf, util, logger, scripts |
---|
5 | |
---|
6 | class ScriptTests( unittest.TestCase ): |
---|
7 | """ |
---|
8 | Testing scripts |
---|
9 | """ |
---|
10 | |
---|
11 | def test_tabs2genetrack(self): |
---|
12 | "Testing bed2genetrack transformation" |
---|
13 | from genetrack.scripts import tabs2genetrack |
---|
14 | |
---|
15 | inpfile = conf.testdata('short-data.bed', verify=True) |
---|
16 | outfile = conf.tempdata('short-data.genetrack') |
---|
17 | tabs2genetrack.transform(inpfile, outfile, format='BED') |
---|
18 | |
---|
19 | def get_suite(): |
---|
20 | "Returns the testsuite" |
---|
21 | tests = [ |
---|
22 | ScriptTests, |
---|
23 | ] |
---|
24 | |
---|
25 | return testlib.make_suite( tests ) |
---|
26 | |
---|
27 | if __name__ == '__main__': |
---|
28 | suite = get_suite() |
---|
29 | logger.disable('DEBUG') |
---|
30 | unittest.TextTestRunner(verbosity=2).run( suite ) |
---|
31 | |
---|
32 | |
---|