Skip to content

Commit b002f2b

Browse files
authored
add 2e2 test to read remote files (#21)
Signed-off-by: Jorge Aguilera <jorge@edn.es>
1 parent 9f28343 commit b002f2b

2 files changed

Lines changed: 17 additions & 1 deletion

File tree

src/e2e/tests/count.nf.test

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,18 @@ nextflow_pipeline {
1212

1313
}
1414

15+
test("Should count an http file") {
16+
17+
when{
18+
params{
19+
url = 'https://github.com/supandatavizz/yellow-trip-parquet/raw/refs/heads/main/yellow_tripdata_2023-01.parquet'
20+
}
21+
}
22+
then {
23+
assert workflow.success
24+
assert workflow.stdout[0] as int == 3066766
25+
}
26+
27+
}
28+
1529
}

src/e2e/workflows/count.nf

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
include { countParquet } from 'plugin/nf-parquet'
22

3-
channel.fromPath("${baseDir}/data/presidents.parquet")
3+
url = params.url ?: "${baseDir}/data/presidents.parquet"
4+
5+
channel.fromPath(url)
46
.countParquet( )
57
| view

0 commit comments

Comments
 (0)