Skip to content
Snippets Groups Projects
Commit eeb76613 authored by Venkat Malladi's avatar Venkat Malladi
Browse files

Add in tests for single end sequencing.

parent b8588c1a
Branches
Tags
1 merge request!6Resolve "Bam Stats and Filter"
Pipeline #1059 failed with stage
in 1 hour, 33 minutes, and 49 seconds
#!/usr/bin/env python3
import pytest
import os
import pandas as pd
test_output_path = os.path.dirname(os.path.abspath(__file__)) + \
'/../output/filterReads/'
def test_map_qc_singleend():
assert os.path.exists(os.path.join(test_output_path, 'ENCFF646LXU.filt.nodup.bam'))
assert os.path.exists(os.path.join(test_output_path, 'ENCFF646LXU.filt.nodup.bam.bai'))
filtered_reads_report = test_output_path + 'ENCFF646LXU.filt.nodup.flagstat.qc'
samtools_report = open(filtered_reads_report).readlines()
assert '64962570 + 0 in total' in samtools_report[0]
assert '64962570 + 0 mapped (100% : N/A)' in samtools_report[4]
library_complexity = test_output_path + 'ENCFF646LXU.filt.nodup.pbc.qc'
df_library_complexity = pd.read_csv(library_complexity, sep='\t')
assert df_library_complexity["NRF"].iloc[0] == 0.926192
assert df_library_complexity["PBC1"].iloc[0] == 0.926775
assert df_library_complexity["PBC2"].iloc[0] == 13.706885
def test_map_qc_pairedend():
# Do the same thing for paired end data
pass
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment