diff --git a/HISTORY.rst b/HISTORY.rst index b677f3c75..313cdc44a 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -9,12 +9,14 @@ HEAD (unreleased) End-User Summary ================ +- Adding "not hom. alt." filter setting. - Allowing users to easily copy case UUID by icon in case heading. - Fixing bug that made the user icon top right disappear. Full Change List ================ +- Adding "not hom. alt." filter setting. - Improving admin configuration documentation. - Extending admin tuning documentation. - Allowing users to easily copy case UUID by icon in case heading. diff --git a/variants/forms.py b/variants/forms.py index d1467a865..33272ec9d 100644 --- a/variants/forms.py +++ b/variants/forms.py @@ -126,6 +126,7 @@ class Meta: ("ref", "0/0"), ("het", "0/1"), ("hom", "1/1"), + ("non-hom", "0/0 or 0/1"), ("variant", "variant"), ("non-variant", "non-variant"), ("non-reference", "non-reference"), @@ -178,6 +179,7 @@ class Meta: "ref": ("0/0", "0|0", "0"), "het": ("0/1", "0|1", "1/0", "1|0", "1"), "hom": ("1/1", "1|1", "1"), + "non-hom": ("0/0", "0|0", "0", "0/1", "0|1", "1/0", "1|0", "1"), "reference": ("0/0", "0|0", "0"), "variant": ("1/0", "1|0", "0/1", "0|1", "1/1", "1|1", "1"), "non-variant": ("0/0", "./.", "0"), diff --git a/variants/tests/test_queries.py b/variants/tests/test_queries.py index ad3a63e81..09e0609b3 100644 --- a/variants/tests/test_queries.py +++ b/variants/tests/test_queries.py @@ -2192,6 +2192,15 @@ def test_genotype_gt_variant_export(self): def test_genotype_gt_variant_vcf(self): self.run_query(CaseExportVcfQuery, {"%s_gt" % self.patient: "variant"}, 6) + def test_genotype_gt_non_hom_filter(self): + self.run_query(CasePrefetchQuery, {"%s_gt" % self.patient: "non-hom"}, 6) + + def test_genotype_gt_non_hom_export(self): + self.run_query(CaseExportTableQuery, {"%s_gt" % self.patient: "non-hom"}, 6) + + def test_genotype_gt_non_hom_vcf(self): + self.run_query(CaseExportVcfQuery, {"%s_gt" % self.patient: "non-hom"}, 6) + def test_genotype_gt_non_variant_filter(self): self.run_query(CasePrefetchQuery, {"%s_gt" % self.patient: "non-variant"}, 2)