-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
95c0f5c
commit 0b2ba27
Showing
10 changed files
with
119 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
id address level_1 | ||
sample1 1 1 | ||
sample2 1 1 | ||
sample3 2 2 | ||
sampleQ 1 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
id address level_1 | ||
sample1 1 1 | ||
sample2 1 1 | ||
sample3 2 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
query_id ref_id dist | ||
sampleQ sampleQ 0 | ||
sampleQ sample1 1 | ||
sampleQ sample2 1 | ||
sampleQ sample3 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"files": { | ||
"global": [ | ||
|
||
], | ||
"samples": { | ||
|
||
} | ||
}, | ||
"metadata": { | ||
"samples": { | ||
"sampleQ": { | ||
"address": "1" | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
sample_id l1 l2 l3 | ||
sampleQ 1 2 1 | ||
sample1 1 1 1 | ||
sample2 - 1 1 | ||
sample3 - 1 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
sample_id l1 l2 l3 | ||
sampleQ 1 2 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"sample2": { | ||
"l1": "-", | ||
"l2": "1", | ||
"l3": "1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"sample3": { | ||
"l1": "-", | ||
"l2": "1", | ||
"l3": "2" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
sample,mlst_alleles,address | ||
sampleQ,https://raw.githubusercontent.com/phac-nml/gasnomenclature/dev/tests/data/reports/sampleQ.mlst.json, | ||
sample1,https://raw.githubusercontent.com/phac-nml/gasnomenclature/dev/tests/data/reports/sample1.mlst.json,1 | ||
sample2,https://raw.githubusercontent.com/phac-nml/gasnomenclature/add_tests/tests/data/reports/sample2_missing.mlst.json,1 | ||
sample3,https://raw.githubusercontent.com/phac-nml/gasnomenclature/add_tests/tests/data/reports/sample3_missing.mlst.json,2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
nextflow_pipeline { | ||
|
||
name "Integration Tests for parameters dealing with missing or removed alleles" | ||
script "main.nf" | ||
|
||
test("Full pipeline hashes and missing data") { | ||
tag "pipeline_hashes_missing" | ||
|
||
when { | ||
params { | ||
input = "$baseDir/tests/data/samplesheets/samplesheet-hash_missing.csv" | ||
outdir = "results" | ||
|
||
gm_thresholds = "1" | ||
} | ||
} | ||
|
||
then { | ||
assert workflow.success | ||
assert path("$launchDir/results").exists() | ||
|
||
// Check merged profiles | ||
def actual_profile_ref = path("$launchDir/results/locidex/merge/reference/merged_ref/merged_profiles_ref.tsv") | ||
def expected_profile_tsv = path("$baseDir/tests/data/profiles/expected-profile_missing1.tsv") | ||
assert actual_profile_ref.text == expected_profile_tsv.text | ||
|
||
// Check query profiles | ||
def actual_profile_query = path("$launchDir/results/locidex/merge/query/merged_value/merged_profiles_value.tsv") | ||
def expected_profile_query_tsv = path("$baseDir/tests/data/profiles/expected-profile_missing2.tsv") | ||
assert actual_profile_query.text == expected_profile_query_tsv.text | ||
|
||
// Check computed pairwise distances | ||
def actual_distances = path("$launchDir/results/distances/results.text") | ||
def expected_distances = path("$baseDir/tests/data/distances/expected_dists_missing.txt") | ||
assert actual_distances.text == expected_distances.text | ||
|
||
// Verify cluster file | ||
def actual_cluster = path("$launchDir/results/cluster/reference_clusters.txt") | ||
def expected_cluster = path("$baseDir/tests/data/clusters/expected_clusters_missing.txt") | ||
assert actual_cluster.text == expected_cluster.text | ||
|
||
// Check called clusters | ||
def actual_calls = path("$launchDir/results/call/Called/results.text") | ||
def expected_calls = path("$baseDir/tests/data/called/expected_results_missing.txt") | ||
assert actual_calls.text == expected_calls.text | ||
|
||
// Check IRIDA Next JSON output | ||
assert path("$launchDir/results/iridanext.output.json").json == path("$baseDir/tests/data/irida/missing_iridanext.output.json").json | ||
|
||
def iridanext_json = path("$launchDir/results/iridanext.output.json").json | ||
def iridanext_samples = iridanext_json.files.samples | ||
def iridanext_metadata = iridanext_json.metadata.samples | ||
|
||
assert iridanext_metadata.size() == 1 && iridanext_metadata.containsKey("sampleQ") | ||
assert iridanext_metadata.sampleQ."address" == "1" | ||
} | ||
} | ||
|
||
|
||
} | ||
|