Skip to content

Commit d01abbc

Browse files
authored
Merge pull request #105 from cancervariants/issue-103
Issue 103
2 parents fad3626 + 31baa9b commit d01abbc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+2193
-510
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
"""Module for package and distribution."""
22
import setuptools
33

4-
setuptools.setup(version="0.2.1")
4+
setuptools.setup(version="0.2.2")
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
"""Module for testing Amino Acid Deletion Classifier."""
2+
import unittest
3+
from variant.classifiers import AminoAcidDeletionClassifier
4+
from .classifier_base import ClassifierBase
5+
6+
7+
class TestAminoAcidDeletionClassifier(ClassifierBase, unittest.TestCase):
8+
"""A class to test the Amino Acid Deletion Classifier."""
9+
10+
def classifier_instance(self):
11+
"""Return AminoAcidDeletionClassifier instance."""
12+
return AminoAcidDeletionClassifier()
13+
14+
def fixture_name(self):
15+
"""Return AminoAcidDeletionClassifier fixture name."""
16+
return 'amino_acid_deletion'
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
"""Module for testing Coding DNA Deletion Classifier."""
2+
import unittest
3+
from variant.classifiers import CodingDNADeletionClassifier
4+
from .classifier_base import ClassifierBase
5+
6+
7+
class TestCodingDNADeletionClassifier(ClassifierBase, unittest.TestCase):
8+
"""A class to test the Coding DNA Deletion Classifier."""
9+
10+
def classifier_instance(self):
11+
"""Return CodingDNADeletionClassifier instance."""
12+
return CodingDNADeletionClassifier()
13+
14+
def fixture_name(self):
15+
"""Return CodingDNADeletionClassifier fixture name."""
16+
return 'coding_dna_deletion'
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
"""Module for testing Genomic Deletion Classifier."""
2+
import unittest
3+
from variant.classifiers import GenomicDeletionClassifier
4+
from .classifier_base import ClassifierBase
5+
6+
7+
class TestGenomicDeletionClassifier(ClassifierBase, unittest.TestCase):
8+
"""A class to test the Genomic Deletion Classifier."""
9+
10+
def classifier_instance(self):
11+
"""Return GenomicDeletionClassifier instance."""
12+
return GenomicDeletionClassifier()
13+
14+
def fixture_name(self):
15+
"""Return GenomicDeletionClassifier fixture name."""
16+
return 'genomic_deletion'

tests/fixtures/classifiers.yml

Lines changed: 63 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ polypeptide_truncation:
5252
- query: ENSP00000343204.4:p.Trp690Ter
5353
confidence: ConfidenceRating.EXACT
5454
should_not_match:
55-
- query: ENSP00000343204.4:c.Trp690Ter
55+
- query: ENS00000343204.4:c.Trp690Ter
5656

5757
silent_mutation:
5858
should_match:
@@ -169,3 +169,65 @@ genomic_delins:
169169
should_not_match:
170170
- query: N_000017.10:c.1423_1424delinsGT
171171
- query: g.1423delinsX
172+
173+
amino_acid_deletion:
174+
should_match:
175+
- query: NP_004439.2:p.Leu755_Thr759del
176+
confidence: ConfidenceRating.EXACT
177+
- query: NP_000213.1:p.Val560del
178+
confidence: ConfidenceRating.EXACT
179+
- query: NP_000213.1:p.Lys550_Lys558del
180+
confidence: ConfidenceRating.EXACT
181+
- query: LRG_199p1:p.Val7del
182+
confidence: ConfidenceRating.EXACT
183+
- query: LRG_199p1:p.(Val7del)
184+
confidence: ConfidenceRating.EXACT
185+
- query: KIT D419del
186+
confidence: ConfidenceRating.EXACT
187+
- query: KIT E554_V559del
188+
confidence: ConfidenceRating.EXACT
189+
- query: CTNNB1 Y30_I35del
190+
confidence: ConfidenceRating.EXACT
191+
- query: ENSP00000256474.2:p.Phe76del
192+
confidence: ConfidenceRating.EXACT
193+
- query: NP_004439.2:c.Leu755_Thr759del
194+
confidence: ConfidenceRating.INTERSECTION
195+
should_not_match:
196+
- query: fakegene Leu755_Thr759delLeu
197+
- query: GENE c.L755del
198+
199+
coding_dna_deletion:
200+
should_match:
201+
- query: ENST00000269571.5:c.2263_2277del
202+
confidence: ConfidenceRating.EXACT
203+
- query: NM_004448.3:c.2263_2277delTTGAGGGAAAACACA
204+
confidence: ConfidenceRating.EXACT
205+
- query: NM_000535.6:c.2117delA
206+
confidence: ConfidenceRating.EXACT
207+
- query: ENST00000256474.2:c.163delG
208+
confidence: ConfidenceRating.EXACT
209+
- query: NM_004333.4:c.1799_1800delTGinsAT
210+
confidence: ConfidenceRating.INTERSECTION
211+
- query: ENST00000257290.5:c.2524_2525delinsAT
212+
confidence: ConfidenceRating.INTERSECTION
213+
- query: MLH1 c.1852_1854delAAG
214+
confidence: ConfidenceRating.EXACT
215+
should_not_match:
216+
- query: GENE c.1799_1800delTGinsAT
217+
- query: GENE c.2524_2525delinsAT
218+
219+
genomic_deletion:
220+
should_match:
221+
- query: NC_000017.10:g.37880219_37880233del
222+
confidence: ConfidenceRating.EXACT
223+
- query: NC_000004.11:g.55593610_55593615delTTGTTG
224+
confidence: ConfidenceRating.EXACT
225+
- query: NC_000003.11:g.10183645del
226+
confidence: ConfidenceRating.EXACT
227+
- query: NC_000003.11:g.10188302delG
228+
confidence: ConfidenceRating.EXACT
229+
- query: NC_000006.11:g.152419920_152419921delinsAG
230+
confidence: ConfidenceRating.INTERSECTION
231+
should_not_match:
232+
- query: GENE g.152419920_152419921delinsAG
233+
- query: GENE g.152419920_152419921delAinsG

tests/fixtures/tokenizers.yml

Lines changed: 58 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,4 +250,61 @@ locus_reference_genomic:
250250
- token: LRG_t1
251251
- token: LRG_p1
252252
- token: LRGt1
253-
- token: LRGp1
253+
- token: LRGp1
254+
255+
amino_acid_deletion:
256+
should_match:
257+
- token: p.Val7del
258+
- token: Val7del
259+
- token: p.(Val7del)
260+
- token: (Val7del)
261+
- token: p.V7del
262+
- token: V7del
263+
- token: p.(V7del)
264+
- token: (V7del)
265+
- token: Lys23_Val25del
266+
- token: p.Lys23_Val25del
267+
- token: p.(Lys23_Val25del)
268+
- token: (Lys23_Val25del)
269+
- token: p.Phe76del
270+
should_not_match:
271+
- token: Val7deletion
272+
- token: (Val7deletion)
273+
- token: p.Val7deletion
274+
- token: c.Val7del
275+
- token: ValSup7del
276+
- token: delVal7
277+
- token: 7Valdel
278+
- token: Val7_Glydel
279+
- token: Val_Gly7del
280+
281+
coding_dna_deletion:
282+
should_match:
283+
- token: c.2263_2277del
284+
- token: c.1608del
285+
- token: c.2263_2277delTTGAGGGAAAACACA
286+
- token: c.163delG
287+
- token: c.435_436delGC
288+
should_not_match:
289+
- token: g.2263_2277del
290+
- token: g.1608del
291+
- token: c.del
292+
- token: 2263_2277del
293+
- token: c._2277del
294+
- token: c.2263_del
295+
- token: c.2263
296+
297+
genomic_deletion:
298+
should_match:
299+
- token: g.37880219_37880233del
300+
- token: g.139390650del
301+
- token: g.55593610_55593615delTTGTTG
302+
- token: g.10191495delT
303+
should_not_match:
304+
- token: c.37880219_37880233del
305+
- token: c.139390650del
306+
- token: g.del
307+
- token: 37880219_37880233del
308+
- token: g._37880233del
309+
- token: g._37880233del
310+
- token: g.37880219

tests/fixtures/translators.yml

Lines changed: 140 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1193,6 +1193,40 @@ coding_dna_delins:
11931193
"type": "SequenceState"
11941194
},
11951195
"type": "Allele"
1196+
},
1197+
{
1198+
"id": "ga4gh:VA.ZEi2I_lEtXSGqQWsUX0ZSPPFHLoBSajx",
1199+
"location": {
1200+
"interval": {
1201+
"start": 900,
1202+
"end": 901,
1203+
"type": "SimpleInterval"
1204+
},
1205+
"sequence_id": "ga4gh:SQ.CMHotHdJwhFah2_gNdlwU7DTT4yv-x_1",
1206+
"type": "SequenceLocation"
1207+
},
1208+
"state": {
1209+
"sequence": "C",
1210+
"type": "SequenceState"
1211+
},
1212+
"type": "Allele"
1213+
},
1214+
{
1215+
"id": "ga4gh:VA.I5hyMcbe5HIraTCswrEUVNwJ7nIfTcKx",
1216+
"location": {
1217+
"interval": {
1218+
"start": 900,
1219+
"end": 901,
1220+
"type": "SimpleInterval"
1221+
},
1222+
"sequence_id": "ga4gh:SQ.xpx15sumYFV5iNvkVnWPR4YQFIzHqXj9",
1223+
"type": "SequenceLocation"
1224+
},
1225+
"state": {
1226+
"sequence": "C",
1227+
"type": "SequenceState"
1228+
},
1229+
"type": "Allele"
11961230
}
11971231
]
11981232

@@ -1271,4 +1305,110 @@ genomic_delins:
12711305
},
12721306
"type": "Allele"
12731307
}
1308+
]
1309+
1310+
amino_acid_deletion:
1311+
tests:
1312+
- query: NP_000542.1:p.Phe76del
1313+
variants: [
1314+
{
1315+
"id": "ga4gh:VA.P6K_G0ZM2KZdvCfG0U0P_OtHgGxZfdd9",
1316+
"location": {
1317+
"interval": {
1318+
"end": 76,
1319+
"start": 75,
1320+
"type": "SimpleInterval"
1321+
},
1322+
"sequence_id": "ga4gh:SQ.z-Oa0pZkJ6GHJHOYM7h5mY_umc0SJzTu",
1323+
"type": "SequenceLocation"
1324+
},
1325+
"state": {
1326+
"sequence": "",
1327+
"type": "SequenceState"
1328+
},
1329+
"type": "Allele"
1330+
}
1331+
]
1332+
- query: NP_000542.1:p.Arg82_Val84del
1333+
variants: [
1334+
{
1335+
"id": "ga4gh:VA.1ZjAyIGY2Uwb4_ItKPII33nGbvrtAQmL",
1336+
"location": {
1337+
"interval": {
1338+
"end": 84,
1339+
"start": 81,
1340+
"type": "SimpleInterval"
1341+
},
1342+
"sequence_id": "ga4gh:SQ.z-Oa0pZkJ6GHJHOYM7h5mY_umc0SJzTu",
1343+
"type": "SequenceLocation"
1344+
},
1345+
"state": {
1346+
"sequence": "",
1347+
"type": "SequenceState"
1348+
},
1349+
"type": "Allele"
1350+
}
1351+
]
1352+
1353+
coding_dna_deletion:
1354+
tests:
1355+
- query: NM_004448.3:c.2263_2277delTTGAGGGAAAACACA
1356+
variants: [
1357+
{
1358+
"id": "ga4gh:VA.g_DrfzkfKKB1p8LTPvYLn3pIDBgrPV0K",
1359+
"location": {
1360+
"interval": {
1361+
"end": 2278,
1362+
"start": 2263,
1363+
"type": "SimpleInterval"
1364+
},
1365+
"sequence_id": "ga4gh:SQ.y9b4LVMiCXpZxOg9Xt1NwRtssA03MwWM",
1366+
"type": "SequenceLocation"
1367+
},
1368+
"state": {
1369+
"sequence": "",
1370+
"type": "SequenceState"
1371+
},
1372+
"type": "Allele"
1373+
}
1374+
]
1375+
1376+
genomic_deletion:
1377+
tests:
1378+
- query: NC_000003.11:g.10191486_10191487delAG
1379+
variants: [
1380+
{
1381+
"id": "ga4gh:VA.IgGURw7vLMl10__vUKN876XOXpsgGOxt",
1382+
"location": {
1383+
"interval": {
1384+
"end": 481,
1385+
"start": 477,
1386+
"type": "SimpleInterval"
1387+
},
1388+
"sequence_id": "ga4gh:SQ.xBKOKptLLDr-k4hTyCetvARn16pDS_rW",
1389+
"type": "SequenceLocation"
1390+
},
1391+
"state": {
1392+
"sequence": "TG",
1393+
"type": "SequenceState"
1394+
},
1395+
"type": "Allele"
1396+
},
1397+
{
1398+
"id": "ga4gh:VA.3A2p6mLNdf82X5TKu7zoXvqBeNO9hpRV",
1399+
"location": {
1400+
"interval": {
1401+
"end": 10191487,
1402+
"start": 10191483,
1403+
"type": "SimpleInterval"
1404+
},
1405+
"sequence_id": "ga4gh:SQ.VNBualIltAyi2AI_uXcKU7M9XUOuA7MS",
1406+
"type": "SequenceLocation"
1407+
},
1408+
"state": {
1409+
"sequence": "AG",
1410+
"type": "SequenceState"
1411+
},
1412+
"type": "Allele"
1413+
}
12741414
]

tests/fixtures/validators.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,3 +105,45 @@ genomic_delins:
105105
should_not_match:
106106
- query: NC_000023.21:g.32386323delinsGA
107107
- query: NC_000023.11:g.3238646549879323delinsGA
108+
109+
amino_acid_deletion:
110+
should_match:
111+
- query: NP_003997.1:p.Lys23_Val25del
112+
- query: NP_003997.1:p.(Lys23_Val25del)
113+
- query: NP_000542.1:p.Glu186del
114+
- query: NP_000542.1:p.(Glu186del)
115+
- query: NP_000542.1:p.Arg82_Val84del
116+
- query: ENSP00000256474.2:p.Phe76del
117+
- query: KIT D419del
118+
- query: KIT E554_V559del
119+
- query: LRG_322p1:p.Leu128del
120+
- query: LRG_199p1:p.Val7del
121+
- query: LRG_199p1:p.(Val7del)
122+
- query: LRG_199p1:p.Trp4del
123+
- query: LRG_232p1:p.(Pro458_Gly460del)
124+
should_not_match:
125+
- query: LRG_199p1:p.Ala7del
126+
- query: LRG_199p1:p.Val78848498879del
127+
128+
coding_dna_deletion:
129+
should_match:
130+
- query: ENST00000269571.5:c.2263_2277del
131+
- query: NM_004448.3:c.2263_2277delTTGAGGGAAAACACA
132+
- query: ERBB2 c.2263_2277delTTGAGGGAAAACACA
133+
- query: NM_004448.3:c.2263_2277del
134+
- query: NM_000535.6:c.2117delA
135+
- query: NM_000535.6:c.2117del
136+
should_not_match:
137+
- query: NM_000535.6:c.2117delT
138+
- query: NM_000535.6:c.21145457delA
139+
140+
genomic_deletion:
141+
should_match:
142+
- query: NC_000003.11:g.10188279_10188297del
143+
- query: NC_000003.11:g.10191486_10191487delAG
144+
- query: NC_000003.12:g.10146527_10146528del
145+
- query: NC_000003.11:g.10191495delT
146+
- query: VHL g.10188279_10188297del
147+
should_not_match:
148+
- query: NC_000003.11:g.10188302delT
149+
- query: NC_000003.11:g.10191454654654654495delT

0 commit comments

Comments
 (0)