1- import pytest
2-
3- from malariagen_data import Adar1 , Region
4- from malariagen_data .util import _locate_region , _resolve_region
1+ from malariagen_data import Adar1
52
63
74def setup_adar1 (url = "simplecache::gs://vo_adar_release_master_us_central1/" , ** kwargs ):
@@ -18,14 +15,14 @@ def setup_adar1(url="simplecache::gs://vo_adar_release_master_us_central1/", **k
1815 return Adar1 (url , ** kwargs )
1916
2017
21- #def test_repr():
18+ # def test_repr():
2219# adar1 = setup_adar1(check_location=True)
2320# assert isinstance(adar1, Adar1)
2421# assert isinstance(r, str)
2522# r = repr(adar1)
2623
2724
28- #@pytest.mark.parametrize(
25+ # @pytest.mark.parametrize(
2926# "region_raw",
3027# [
3128# "2",
@@ -34,8 +31,8 @@ def setup_adar1(url="simplecache::gs://vo_adar_release_master_us_central1/", **k
3431# "2:2,630,355-2,633,221",
3532# Region("2", 4871446, 4871535),
3633# ],
37- #)
38- #def test_locate_region(region_raw):
34+ # )
35+ # def test_locate_region(region_raw):
3936# # TODO Migrate this test.
4037# adar1 = setup_adar1()
4138# gene_annotation = adar1.geneset(attributes=["ID"])
@@ -45,32 +42,32 @@ def setup_adar1(url="simplecache::gs://vo_adar_release_master_us_central1/", **k
4542# # ref = adar1.snp_sites(region=region.contig, field="REF")
4643# loc_region = _locate_region(region, pos)
4744
48- # check types
45+ # check types
4946# assert isinstance(loc_region, slice)
5047# assert isinstance(region, Region)
5148
52- # check Region with contig
49+ # check Region with contig
5350# if region_raw == "2":
5451# assert region.contig == "2"
5552# assert region.start is None
5653# assert region.end is None
5754
58- # check that Region goes through unchanged
55+ # check that Region goes through unchanged
5956# if isinstance(region_raw, Region):
6057# assert region == region_raw
6158
62- # check that gene name matches coordinates from the geneset and matches gene sequence
59+ # check that gene name matches coordinates from the geneset and matches gene sequence
6360# if region_raw == "gene-LOC125950257":
6461# gene = gene_annotation.query("ID == 'gene-LOC125950257'").squeeze()
6562# assert region == Region(gene.contig, gene.start, gene.end)
6663# assert pos[loc_region][0] == gene.start
6764# assert pos[loc_region][-1] == gene.end
68- # To be checked
69- # assert (
70- # ref[loc_region][:5].compute() == np.array(["T", "T", "G", "T", "T"])
71- # ).all()
65+ # To be checked
66+ # assert (
67+ # ref[loc_region][:5].compute() == np.array(["T", "T", "G", "T", "T"])
68+ # ).all()
7269
73- # check string parsing
70+ # check string parsing
7471# if region_raw == "2:4871446-4871535":
7572# assert region == Region("2", 4871446, 4871535)
7673# if region_raw == "2:2,630,355-2,633,221":
0 commit comments