Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: implementing Default for AnnField #215

Merged
merged 1 commit into from
Oct 16, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions src/annotate/seqvars/ann.rs
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,33 @@
pub messages: Option<Vec<Message>>,
}

impl Default for AnnField {
fn default() -> Self {

Check warning on line 532 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L532

Added line #L532 was not covered by tests
Self {
allele: Allele::Alt {

Check warning on line 534 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L534

Added line #L534 was not covered by tests
alternative: Default::default(),
},
consequences: vec![],

Check warning on line 537 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L537

Added line #L537 was not covered by tests
putative_impact: PutativeImpact::Modifier,
gene_symbol: Default::default(),
gene_id: Default::default(),
feature_type: FeatureType::SoTerm {

Check warning on line 541 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L539-L541

Added lines #L539 - L541 were not covered by tests
term: SoFeature::Transcript,
},
feature_id: Default::default(),

Check warning on line 544 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L544

Added line #L544 was not covered by tests
feature_biotype: FeatureBiotype::Coding,
rank: Default::default(),
hgvs_t: Default::default(),
hgvs_p: Default::default(),
tx_pos: Default::default(),
cds_pos: Default::default(),
protein_pos: Default::default(),
distance: Default::default(),
messages: Default::default(),

Check warning on line 553 in src/annotate/seqvars/ann.rs

View check run for this annotation

Codecov / codecov/patch

src/annotate/seqvars/ann.rs#L546-L553

Added lines #L546 - L553 were not covered by tests
}
}
}

impl FromStr for AnnField {
type Err = anyhow::Error;

Expand Down
Loading