Package org.snpsift.testCases.unit
Class TestCasesAnnotate
java.lang.Object
org.snpsift.testCases.unit.TestCasesAnnotate
- Direct Known Subclasses:
TestCasesAnnotateCreateIndex
,TestCasesAnnotateMem
,TestCasesAnnotateTabix
,TestCasesAnnotateUseIndex
Annotate test case
- Author:
- pcingola
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic boolean
protected String[]
protected boolean
static boolean
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionList
<org.snpeff.vcf.VcfEntry> AnnotateannotateOut
(String dbFileName, String fileName, String[] extraArgs) Annotate and return STDOUT as a stringvoid
annotateTest
(String dbFileName, String fileName) void
annotateTest
(String dbFileName, String fileName, String[] extraArgs) Annotate a file and check that the new annotation matches the expected oneprotected String[]
void
test_01()
void
test_02()
void
test_03()
void
test_04()
void
test_05()
Chromosomes in VCF file are called 'chr22' instead of '22'.void
test_06()
Annotate info fieldsvoid
test_07()
Annotate only some info fieldsvoid
test_08()
Do not annotate ID columnvoid
test_09()
Annotate only some info fieldsvoid
test_11()
Annotate only some info fieldsvoid
test_12()
Annotate without REF/ALT fieldsvoid
test_13()
Annotate using "reserved" VCF fields (e.g.void
test_14()
void
test_15()
void
test_16()
void
test_17()
void
test_18()
void
test_19()
void
test_20()
Annotate info fieldsvoid
test_21()
Annotate two consecutive variants in the same positionvoid
test_22()
Annotate first base in a chromosomevoid
Database has one entry and VCF has multiple ALTsvoid
test_24()
Annotate using "-name" to prepend a name to VCF fields (e.g.void
test_25()
Annotate using "-name" to prepend a name to VCF fields (e.g.void
Annotate ID using entries that are duplicated in db.vcfvoid
Annotate INFO fields using entries that are duplicated in db.vcfvoid
Annotate if a VCF entry exists in the database filevoid
Annotate if a VCF entry's ID might have multiple repeated entriesvoid
Issue when database has REF several variants which have to be converted into minimal representationvoid
Issue when query has REF several variants which have to be converted into minimal representationvoid
Empty databasevoid
Database has one entry and VCF has multiple ALTsvoid
test_35()
Annotate flags without '=true'void
test_36()
Annotate multi-allelicvoid
test_38()
Input VCf triggers a seek to a position after chromosome sections ends in database.void
test_39()
Annotate issues with discovered info fields (when annotating ALL info fields)void
test_40()
Problems when tabix database file has 'chr' in chromosome names and VCF file does notvoid
test_41()
void
test_42()
Test multiple CAF annotationsvoid
test_43()
Annotate emptyvoid
test_44()
Annotate GnomAd with multiple entriesvoid
test_45()
Annotate GnomAd with multiple entries
-
Field Details
-
debug
public static boolean debug -
verbose
public static boolean verbose -
defaultExtraArgs
-
deleteIndexFile
protected boolean deleteIndexFile
-
-
Constructor Details
-
TestCasesAnnotate
public TestCasesAnnotate()
-
-
Method Details
-
annotate
public List<org.snpeff.vcf.VcfEntry> annotate(String dbFileName, String fileName, String[] extraArgs) Annotate -
annotateOut
Annotate and return STDOUT as a string -
annotateTest
-
annotateTest
Annotate a file and check that the new annotation matches the expected one -
argsList
-
test_01
public void test_01() -
test_02
public void test_02() -
test_03
public void test_03() -
test_04
public void test_04() -
test_05
public void test_05()Chromosomes in VCF file are called 'chr22' instead of '22'. This should work OK as well. -
test_06
public void test_06()Annotate info fields -
test_07
public void test_07()Annotate only some info fields -
test_08
public void test_08()Do not annotate ID column -
test_09
public void test_09()Annotate only some info fields -
test_11
public void test_11()Annotate only some info fields- Throws:
IOException
-
test_12
public void test_12()Annotate without REF/ALT fields -
test_13
public void test_13()Annotate using "reserved" VCF fields (e.g. "AA" ) Header should be added if it doesn't exits.- Throws:
IOException
-
test_14
public void test_14() -
test_15
public void test_15() -
test_16
public void test_16() -
test_17
public void test_17() -
test_18
public void test_18() -
test_19
public void test_19() -
test_20
public void test_20()Annotate info fields -
test_21
public void test_21()Annotate two consecutive variants in the same position -
test_22
public void test_22()Annotate first base in a chromosome -
test_23_allele_specific_annotation_missing_R
public void test_23_allele_specific_annotation_missing_R()Database has one entry and VCF has multiple ALTs -
test_24
public void test_24()Annotate using "-name" to prepend a name to VCF fields (e.g. "AA" -> "PREPEND_AA") Header should be added changing the ID accordingly -
test_25
public void test_25()Annotate using "-name" to prepend a name to VCF fields (e.g. "AA" -> "PREPEND_AA") Header should be added changing the ID accordingly -
test_26_repeat_db_entry
public void test_26_repeat_db_entry()Annotate ID using entries that are duplicated in db.vcf -
test_27_repeat_db_entry
public void test_27_repeat_db_entry()Annotate INFO fields using entries that are duplicated in db.vcf -
test_28_exists
public void test_28_exists()Annotate if a VCF entry exists in the database file -
test_29_repeated_IDs
public void test_29_repeated_IDs()Annotate if a VCF entry's ID might have multiple repeated entries -
test_31_annotate_minimal_representation_db
public void test_31_annotate_minimal_representation_db()Issue when database has REF several variants which have to be converted into minimal representation -
test_32_annotate_minimal_representation_input
public void test_32_annotate_minimal_representation_input()Issue when query has REF several variants which have to be converted into minimal representation -
test_33_empty_db
public void test_33_empty_db()Empty database -
test_34_dbStartsOnDifferentChromo
public void test_34_dbStartsOnDifferentChromo()Database has one entry and VCF has multiple ALTs -
test_35
public void test_35()Annotate flags without '=true' -
test_36
public void test_36()Annotate multi-allelic -
test_38
public void test_38()Input VCf triggers a seek to a position after chromosome sections ends in database. Previously a bug it forced an infinite loop -
test_39
public void test_39()Annotate issues with discovered info fields (when annotating ALL info fields) -
test_40
public void test_40()Problems when tabix database file has 'chr' in chromosome names and VCF file does not -
test_41
public void test_41() -
test_42
public void test_42()Test multiple CAF annotations -
test_43
public void test_43()Annotate empty -
test_44
public void test_44()Annotate GnomAd with multiple entries -
test_45
public void test_45()Annotate GnomAd with multiple entries
-