@@ -16,7 +16,7 @@ nextflow_process {
1616 """
1717 input[0] = channel.of([
1818 [id: 'sample1'],
19- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribocode.txt', checkIfExists: true),
19+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribocode.txt', checkIfExists: true),
2020 'ribocode'
2121 ])
2222 input[1] = channel.of([
@@ -39,6 +39,10 @@ nextflow_process {
3939 assertAll(
4040 { assert process.success },
4141 { assert snapshot(process.out).match() },
42+ // Every emitted ORF must span a whole number of codons; a
43+ // blockSizes sum not divisible by 3 signals a coordinate /
44+ // reading-frame error in the caller's coordinate parser.
45+ { assert path(process.out.bed12[0][1]).text.readLines().findAll { it.trim() }.every { it.split('\t')[10].split(',').findAll { s -> s }.collect { s -> s.toInteger() }.sum() % 3 == 0 } },
4246 { assert rows.size() > 0 },
4347 { assert rows.every { it[aa].toInteger() > 0 } },
4448 { assert rows.every { it[score] && it[score] != '' } },
@@ -57,7 +61,7 @@ nextflow_process {
5761 """
5862 input[0] = channel.of([
5963 [id: 'sample1'],
60- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotish.pred.txt', checkIfExists: true),
64+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotish.pred.txt', checkIfExists: true),
6165 'ribotish'
6266 ])
6367 input[1] = channel.of([
@@ -80,6 +84,10 @@ nextflow_process {
8084 assertAll(
8185 { assert process.success },
8286 { assert snapshot(process.out).match() },
87+ // Every emitted ORF must span a whole number of codons; a
88+ // blockSizes sum not divisible by 3 signals a coordinate /
89+ // reading-frame error in the caller's coordinate parser.
90+ { assert path(process.out.bed12[0][1]).text.readLines().findAll { it.trim() }.every { it.split('\t')[10].split(',').findAll { s -> s }.collect { s -> s.toInteger() }.sum() % 3 == 0 } },
8391 { assert rows.size() > 0 },
8492 { assert rows.every { it[aa].toInteger() > 0 } },
8593 { assert rows.every { it[score] && it[score] != '' } },
@@ -95,7 +103,7 @@ nextflow_process {
95103 """
96104 input[0] = channel.of([
97105 [id: 'sample1'],
98- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotricer.tsv', checkIfExists: true),
106+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotricer.tsv', checkIfExists: true),
99107 'ribotricer'
100108 ])
101109 input[1] = channel.of([
@@ -123,6 +131,10 @@ nextflow_process {
123131 assertAll(
124132 { assert process.success },
125133 { assert snapshot(process.out).match() },
134+ // Every emitted ORF must span a whole number of codons; a
135+ // blockSizes sum not divisible by 3 signals a coordinate /
136+ // reading-frame error in the caller's coordinate parser.
137+ { assert path(process.out.bed12[0][1]).text.readLines().findAll { it.trim() }.every { it.split('\t')[10].split(',').findAll { s -> s }.collect { s -> s.toInteger() }.sum() % 3 == 0 } },
126138 { assert rows.size() > 0 },
127139 { assert rows.every { it[aa].toInteger() > 0 } },
128140 { assert rows.every { it[score] && it[score] != '' } },
@@ -139,7 +151,7 @@ nextflow_process {
139151 """
140152 input[0] = channel.of([
141153 [id: 'sample1'],
142- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.rpbp.predicted-orfs.bed.gz', checkIfExists: true),
154+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.rpbp.predicted-orfs.bed.gz', checkIfExists: true),
143155 'rpbp'
144156 ])
145157 input[1] = channel.of([
@@ -162,6 +174,10 @@ nextflow_process {
162174 assertAll(
163175 { assert process.success },
164176 { assert snapshot(process.out).match() },
177+ // Every emitted ORF must span a whole number of codons; a
178+ // blockSizes sum not divisible by 3 signals a coordinate /
179+ // reading-frame error in the caller's coordinate parser.
180+ { assert path(process.out.bed12[0][1]).text.readLines().findAll { it.trim() }.every { it.split('\t')[10].split(',').findAll { s -> s }.collect { s -> s.toInteger() }.sum() % 3 == 0 } },
165181 { assert rows.size() > 0 },
166182 { assert rows.every { it[aa].toInteger() > 0 } },
167183 { assert rows.every { it[score] && it[score] != '' && it[score].toDouble() > 0 } },
@@ -179,7 +195,7 @@ nextflow_process {
179195 """
180196 input[0] = channel.of([
181197 [id: 'cohort'],
182- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/cohort.price.orfs.tsv', checkIfExists: true),
198+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/cohort.price.orfs.tsv', checkIfExists: true),
183199 'price'
184200 ])
185201 input[1] = channel.of([
@@ -206,6 +222,10 @@ nextflow_process {
206222 assertAll(
207223 { assert process.success },
208224 { assert snapshot(process.out).match() },
225+ // Every emitted ORF must span a whole number of codons; a
226+ // blockSizes sum not divisible by 3 signals a coordinate /
227+ // reading-frame error in the caller's coordinate parser.
228+ { assert path(process.out.bed12[0][1]).text.readLines().findAll { it.trim() }.every { it.split('\t')[10].split(',').findAll { s -> s }.collect { s -> s.toInteger() }.sum() % 3 == 0 } },
209229 { assert rows.size() > 0 },
210230 { assert rows.every { it[aa].toInteger() > 0 } },
211231 { assert rows.collect { it[cls] }.toSet().any { it != 'other' } },
@@ -222,7 +242,7 @@ nextflow_process {
222242 """
223243 input[0] = channel.of([
224244 [id: 'sample1'],
225- file('https://raw.githubusercontent.com/pinin4fjords/test-datasets/add-orf-prediction-fixtures/data/ genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotish.pred.txt', checkIfExists: true),
245+ file(params.modules_testdata_base_path + ' genomics/homo_sapiens/riboseq_expression/orf_predictions/sample1.ribotish.pred.txt', checkIfExists: true),
226246 'ribotish'
227247 ])
228248 input[1] = channel.of([
0 commit comments