Skip to content

Commit

Permalink
Added CI profile and update conda profile
Browse files Browse the repository at this point in the history
  • Loading branch information
LKress committed Jun 18, 2024
1 parent a882743 commit 31f8dc7
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 15 deletions.
13 changes: 9 additions & 4 deletions nextflow.config
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,23 @@
*/

profiles {
conda { params.enable_conda = true }
conda {
params.enable_conda = true
conda.enabled = true
}
debug { process.beforeScript = 'echo $HOSTNAME' }
test {
params.reference = "$baseDir/test/data/ucsc.hg19.minimal.fasta"
params.input_vcfs = "$baseDir/test/data/test_input.txt"
ci {
params.cpus = 1
params.memory = "3g"
timeline.enabled = false
report.enabled = false
trace.enabled = false
dag.enabled = false
}
test {
params.reference = "$baseDir/test/data/ucsc.hg19.minimal.fasta"
params.input_vcfs = "$baseDir/test/data/test_input.txt"
}
}

// Export this variable to prevent local Python libraries from conflicting with those in the container
Expand Down
4 changes: 2 additions & 2 deletions test/scripts/run_test_0.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ output_folder=test/output/test0

nextflow main.nf --help

nextflow main.nf -profile test,conda --output $output_folder --skip_normalization
nextflow main.nf -profile test,conda,ci --output $output_folder --skip_normalization

# missing SNpEff data folder
nextflow main.nf -profile test,conda --output $output_folder --snpeff_organism hg19
nextflow main.nf -profile test,conda,ci --output $output_folder --snpeff_organism hg19
test ! -d $output_folder
2 changes: 1 addition & 1 deletion test/scripts/run_test_1.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
source test/scripts/assert.sh
output_folder=test/output/test1

nextflow main.nf -profile test,conda --output $output_folder
nextflow main.nf -profile test,conda,ci --output $output_folder

test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 1 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 1 output file!"; exit 1; }
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

source test/scripts/assert.sh
output_folder=test/output/test2
nextflow main.nf -profile test,conda --output $output_folder --filter PASS,MNV
nextflow main.nf -profile test,conda,ci --output $output_folder --filter PASS,MNV
test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 2 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 2 output file!"; exit 1; }
assert_eq `wc -l $output_folder/single_sample/single_sample.normalized.vcf | cut -d' ' -f 1` 34 "Wrong number of variants"
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

source test/scripts/assert.sh
output_folder=test/output/test3
nextflow main.nf -profile test,conda --output $output_folder --skip_decompose_complex
nextflow main.nf -profile test,conda,ci --output $output_folder --skip_decompose_complex
test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 2 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 2 output file!"; exit 1; }
assert_eq `wc -l $output_folder/single_sample/single_sample.normalized.vcf | cut -d' ' -f 1` 47 "Wrong number of variants"
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_4.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@

source test/scripts/assert.sh
output_folder=test/output/test4
nextflow main.nf -profile test,conda --input_vcfs test/data/test_input_no_ad.txt --output $output_folder
nextflow main.nf -profile test,conda,ci --input_vcfs test/data/test_input_no_ad.txt --output $output_folder
test -s $output_folder/sample_no_ad/sample_no_ad.normalized.vcf || { echo "Missing test 4 output file!"; exit 1; }
assert_eq `wc -l $output_folder/sample_no_ad/sample_no_ad.normalized.vcf | cut -d' ' -f 1` 52 "Wrong number of variants"
2 changes: 1 addition & 1 deletion test/scripts/run_test_5.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@

source test/scripts/assert.sh
output_folder=test/output/test5
nextflow main.nf -profile test,conda --output $output_folder --input_vcfs false --input_vcf test/data/test_single_sample.vcf
nextflow main.nf -profile test,conda,ci --output $output_folder --input_vcfs false --input_vcf test/data/test_single_sample.vcf
test -s $output_folder/test_single_sample/test_single_sample.normalized.vcf || { echo "Missing test 4 output file!"; exit 1; }
assert_eq `wc -l $output_folder/test_single_sample/test_single_sample.normalized.vcf | cut -d' ' -f 1` 53 "Wrong number of variants"
2 changes: 1 addition & 1 deletion test/scripts/run_test_6.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L001.bam" >> test/data
echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L002.bam" >> test/data/test_bams.txt

# run
nextflow main.nf -profile test,conda --output $output_folder --input_bams test/data/test_bams.txt
nextflow main.nf -profile test,conda,ci --output $output_folder --input_bams test/data/test_bams.txt

# check results
test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 6 output file!"; exit 1; }
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_7.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ echo -e "single_sample\ttumor:"`pwd`"/test/data/TESTX_S1_L001.bam" >> test/data/
echo -e "single_sample\ttumor:"`pwd`"/test/data/TESTX_S1_L002.bam" >> test/data/test_bams.txt
echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L001.bam" >> test/data/test_bams.txt
echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L002.bam" >> test/data/test_bams.txt
nextflow main.nf -profile test,conda --output $output_folder --input_bams test/data/test_bams.txt --skip_multiallelic_filter
nextflow main.nf -profile test,conda,ci --output $output_folder --input_bams test/data/test_bams.txt --skip_multiallelic_filter
test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 7 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 7 output file!"; exit 1; }
test -s $output_folder/single_sample/single_sample.vaf.vcf || { echo "Missing test 7 output file!"; exit 1; }
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_8.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ echo -e "single_sample\ttumor:"`pwd`"/test/data/TESTX_S1_L002.bam" >> test/data/
echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L001.bam" >> test/data/test_bams.txt
echo -e "single_sample\tnormal:"`pwd`"/test/data/TESTX_S1_L002.bam" >> test/data/test_bams.txt

nextflow main.nf -profile test,conda --output $output_folder --input_bams test/data/test_bams.txt
nextflow main.nf -profile test,conda,ci --output $output_folder --input_bams test/data/test_bams.txt

test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 8 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 8 output file!"; exit 1; }
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/run_test_9.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ source test/scripts/assert.sh
output_folder=test/output/test9
snpeff_datadir=/home/you/snpeff

nextflow main.nf -profile test,conda --output $output_folder --snpeff_organism hg19 --snpeff_datadir $snpeff_datadir
nextflow main.nf -profile test,conda,ci --output $output_folder --snpeff_organism hg19 --snpeff_datadir $snpeff_datadir

test -s $output_folder/single_sample/single_sample.normalized.vcf || { echo "Missing test 1 output file!"; exit 1; }
test -s $output_folder/tumor_normal/tumor_normal.normalized.vcf || { echo "Missing test 1 output file!"; exit 1; }
Expand Down

0 comments on commit 31f8dc7

Please sign in to comment.