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

Add in tests.

parent 562c52bc
1 merge request!23Resolve "Output software versions and methods and references"
Pipeline #3253 canceled with stages
in 30 seconds
......@@ -487,6 +487,8 @@ process diffPeaks {
// Collect Software Versions and references
process softwareReport {
publishDir "$outDir/${task.process}", mode: 'copy'
input:
file trimReads_vf from trimReadsVersions.collect()
......
#!/usr/bin/env python3
import pytest
import os
import utils
test_output_path = os.path.dirname(os.path.abspath(__file__)) + \
'/../output/softwareReport/'
@pytest.mark.singleend
def test_software_references():
assert os.path.exists(os.path.join(test_output_path, 'software_references_mqc.txt'))
@pytest.mark.singleend
def test_nextflow_version():
assert os.path.exists(os.path.join(test_output_path, 'version_nextflow.txt'))
@pytest.mark.singleend
def test_software_versions():
assert os.path.exists(os.path.join(test_output_path, 'software_versions_mqc.yaml'))
@pytest.mark.singleend
def test_software_versions_output():
software_versions = os.path.join(test_output_path, 'software_versions_mqc.yaml')
with open(software_versions, 'r') as stream:
data_loaded = yaml.load(stream)
assert len(data_loaded['data'].split('<dt>')) == 15
@pytest.mark.singleskip_true
def test_software_versions_output_rep():
software_versions = os.path.join(test_output_path, 'software_versions_mqc.yaml')
with open(software_versions, 'r') as stream:
data_loaded = yaml.load(stream)
assert len(data_loaded['data'].split('<dt>')) == 13
#!/usr/bin/env python3
import pytest
import os
import utils
test_output_path = os.path.dirname(os.path.abspath(__file__)) + \
'/../output/softwareReport/'
@pytest.mark.singleend
def test_software_versions():
assert os.path.exists(os.path.join(test_output_path, 'software_versions_mqc.yaml'))
@pytest.mark.singleend
def test_software_versions_output():
software_versions = os.path.join(test_output_path, 'software_versions_mqc.yaml')
with open(software_versions, 'r') as stream:
data_loaded = yaml.load(stream)
assert len(data_loaded['data'].split('<dt>')) == 15
@pytest.mark.singleskip_true
def test_software_versions_output_rep():
software_versions = os.path.join(test_output_path, 'software_versions_mqc.yaml')
with open(software_versions, 'r') as stream:
data_loaded = yaml.load(stream)
assert len(data_loaded['data'].split('<dt>')) == 13
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