-
Notifications
You must be signed in to change notification settings - Fork 214
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c8b8802
commit 3f2e806
Showing
6 changed files
with
327 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# from unittest import TestCase | ||
|
||
import deeptools.correctGCBias | ||
import deeptools.utilities | ||
import os.path | ||
from os import unlink | ||
import pysam | ||
|
||
ROOT = os.path.dirname(os.path.abspath(__file__)) + "/test_data/" | ||
|
||
|
||
def test_correctGCBias(): | ||
""" | ||
Test minimal command line args for correctGCBias | ||
""" | ||
GCbiasFreq = ROOT + 'computeGCBias_result1.tabular' | ||
BAM = ROOT + 'paired_chr2L.bam' | ||
GENOME = ROOT + 'sequence.2bit' | ||
outfile = '/tmp/test_correctbias.bam' | ||
args = "--GCbiasFrequenciesFile {} --bamfile {} --genome {} --effectiveGenomeSize 10050 --correctedFile {}".format(GCbiasFreq, BAM, GENOME, outfile).split() | ||
deeptools.correctGCBias.main(args) | ||
|
||
alignment_count = pysam.AlignmentFile(outfile, "rb").count() | ||
expected_count = 11630 | ||
assert abs(alignment_count - expected_count) < 50 | ||
unlink(outfile) |
Oops, something went wrong.