Skip to content
Snippets Groups Projects
Commit de4d2b8b authored by Jonathan Gesell's avatar Jonathan Gesell
Browse files

Updated test scripts.

parent 415fa462
Branches
Tags
2 merge requests!37v0.0.1,!15Resolve "process_align"
Pipeline #5795 failed with stages
in 11 minutes and 9 seconds
......@@ -38,11 +38,23 @@ parseMetadata:
trimData:
stage: unit
script:
- if [ `nproc` -gt 8 ]; then ncore=8; else ncore=`nproc`; fi
- singularity run 'docker://bicf/trimgalore:1.1' trim_galore --gzip -q 25 --illumina --length 35 --basename 16-1ZX4 -j ${ncore} ./test_data/fastq/16-1ZX4.R1.fastq.gz
- singularity run 'docker://bicf/trimgalore:1.1' trim_galore --gzip -q 25 --illumina --length 35 --paired --basename Q-Y5JA -j ${ncore} ./test_data/fastq/Q-Y5JA.R1.fastq.gz ./test_data/fastq/Q-Y5JA.R2.fastq.gz
- singularity run 'docker://bicf/trimgalore:1.1' trim_galore --gzip -q 25 --illumina --length 35 --basename 16-1ZX4 -j `nproc` ./test_data/fastq/16-1ZX4.R1.fastq.gz
- singularity run 'docker://bicf/trimgalore:1.1' trim_galore --gzip -q 25 --illumina --length 35 --paired --basename Q-Y5JA -j `nproc` ./test_data/fastq/Q-Y5JA.R1.fastq.gz ./test_data/fastq/Q-Y5JA.R2.fastq.gz
- pytest -m trimData
alignReads:
stage: unit
script:
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' hisat2 -p `nproc` --add-chrname --un-gz Q-Y5JA.unal.gz -S Q-Y5JA.sam -x /project/BICF/BICF_Core/shared/gudmap/references/GRCh38.p12/hisat2/genome --rna-strandness FR --no-mixed --no-discordant -1 Q-Y5JA_R1_val_1.fq.gz -2 Q-Y5JA_R2_val_2.fq.gz 1>Q-Y5JA.align.out 2>Q-Y5JA.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools view -1 -@ `nproc` -F 4 -F 8 -F 256 -o Q-Y5JA.bam Q-Y5JA.sam 1>>Q-Y5JA.align.out 2>>Q-Y5JA.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools sort -@ `nproc` -O BAM -o Q-Y5JA.sorted.bam Q-Y5JA.bam 1>>Q-Y5JA.align.out 2>>Q-Y5JA.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools index -@ `nproc` -b Q-Y5JA.sorted.bam Q-Y5JA.sorted.bai 1>>Q-Y5JA.align.out 2>>Q-Y5JA.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' hisat2 -p `nproc` --add-chrname --un-gz 16-1ZX4.unal.gz -S 16-1ZX4.sam -x /project/BICF/BICF_Core/shared/gudmap/references/GRCh38.p12/hisat2/genome --rna-strandness FR -U 16-1ZX4_trimmed.fq.gz 1>16-1ZX4.align.out 2>16-1ZX4.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools view -1 -@ `nproc` -F 4 -F 8 -F 256 -o 16-1ZX4.bam 16-1ZX4.sam 1>>16-1ZX4.align.out 2>>16-1ZX4.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools sort -@ `nproc` -O BAM -o 16-1ZX4.sorted.bam 16-1ZX4.bam 1>>16-1ZX4.align.out 2>>16-1ZX4.align.err
- singularity run 'docker://bicf/gudmaprbkaligner:2.0.0' samtools index -@ `nproc` -b 16-1ZX4.sorted.bam 16-1ZX4.sorted.bai 1>>16-1ZX4.align.out 2>>16-1ZX4.align.err
- pytest -m alignReads
integration_se:
stage: integration
script:
......@@ -51,4 +63,4 @@ integration_se:
integration_pe:
stage: integration
script:
- nextflow run ./workflow/rna-seq.nf --deriva ./test_data/auth/credential.json --bdbag ./test_data/auth/cookies.txt --repRID Q-Y5JA
\ No newline at end of file
- nextflow run ./workflow/rna-seq.nf --deriva ./test_data/auth/credential.json --bdbag ./test_data/auth/cookies.txt --repRID Q-Y5JA
......@@ -18,6 +18,7 @@ def test_alignData_se():
assert utils.count_lines(os.path.join(data_output_path, 'Q-Y5JA.sorted.bam')) == 5805611
assert os.path.exists(os.path.join(data_output_path, 'Q-Y5JA.sorted.bai'))
assert utils.count_lines(os.path.join(data_output_path, 'Q-Y5JA.sorted.bai')) == 12824
def test_alignData_pe():
assert os.path.exists(os.path.join(data_output_path, 'Q-Y5JA.unal.gz'))
assert utils.count_lines(os.path.join(data_output_path, 'Q-Y5JA.unal.gz')) == 0
......@@ -25,6 +26,8 @@ def test_alignData_pe():
assert utils.count_lines(os.path.join(data_output_path, 'Q-Y5JA.sorted.bam')) == 5805611
assert os.path.exists(os.path.join(data_output_path, 'Q-Y5JA.sorted.bai'))
assert utils.count_lines(os.path.join(data_output_path, 'Q-Y5JA.sorted.bai')) == 12824
@pytest.mark.alignLogs
def test_alignLogs_se():
assert os.path.exists(os.path.join(logs_output_path, '16-1ZX4.align.err'))
......@@ -32,6 +35,7 @@ def test_alignLogs_se():
assert '34497376 reads; of these:' in open(os.path.join(logs_output_path, '16-1ZX4.align.err')).readlines()[0]
assert os.path.exists(os.path.join(logs_output_path, '16-1ZX4.align.out'))
assert utils.count_lines(os.path.join(logs_output_path, '16-1ZX4.align.out')) == 0
def test_alignLogs_pe():
assert os.path.exists(os.path.join(logs_output_path, 'Q-Y5JA.align.err'))
assert utils.count_lines(os.path.join(logs_output_path, 'Q-Y5JA.align.err')) == 7
......
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