Skip to content

Commit f441bd4

Browse files
Jon BrenasJon Brenas
authored andcommitted
Ruffing
1 parent b0d1f3c commit f441bd4

1 file changed

Lines changed: 16 additions & 17 deletions

File tree

tests/integration/test_ag3.py

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55

66
from malariagen_data import Ag3, Region
77
from malariagen_data.util import _locate_region, _resolve_region
8-
import xarray as xr
98

109

1110
contigs = "2R", "2L", "3R", "3L", "X"
@@ -279,14 +278,14 @@ def test_plot_haplotype_network_none(mocker):
279278
assert call_args["ht_color_counts"] is None
280279

281280

282-
#def test_phenotype_data():
281+
# def test_phenotype_data():
283282
# """Test basic functionality of phenotype_data method with sample_query."""
284283
# ag3 = setup_ag3()
285284

286285
# sample_set = "1237-VO-BJ-DJOGBENOU-VMF00050"
287286
# insecticide_query = "Deltamethrin"
288287

289-
# Use sample_query for filtering
288+
# Use sample_query for filtering
290289
# df = ag3.phenotype_data(
291290
# sample_sets=sample_set, sample_query=f"insecticide == '{insecticide_query}'"
292291
# )
@@ -297,7 +296,7 @@ def test_plot_haplotype_network_none(mocker):
297296
# for col in expected_cols:
298297
# assert col in df.columns
299298

300-
# Check data content
299+
# Check data content
301300
# assert len(df) > 0
302301
# assert all(df["insecticide"] == insecticide_query) # Check if filter was applied
303302
# assert set(df["phenotype"].str.lower().unique()).issubset(
@@ -308,11 +307,11 @@ def test_plot_haplotype_network_none(mocker):
308307
# "susceptible",
309308
# "died",
310309
# "survived",
311-
} # Include all possible values
310+
# } # Include all possible values
312311
# )
313312
# assert sample_set in df["sample_set"].unique()
314313

315-
# Test with multiple query conditions
314+
# Test with multiple query conditions
316315
# df_multi_query = ag3.phenotype_data(
317316
# sample_sets=sample_set,
318317
# sample_query=f"insecticide == '{insecticide_query}' and dose == 0.5",
@@ -323,7 +322,7 @@ def test_plot_haplotype_network_none(mocker):
323322
# assert all(df_multi_query["dose"] == 0.5)
324323

325324

326-
#def test_phenotype_binary_functionality():
325+
# def test_phenotype_binary_functionality():
327326
# """Test phenotype_binary method using sample_query for filtering."""
328327
# ag3 = setup_ag3()
329328

@@ -372,15 +371,15 @@ def test_plot_haplotype_network_none(mocker):
372371
# assert binary_series_empty.name == "phenotype_binary"
373372

374373

375-
#@pytest.mark.parametrize(
374+
# @pytest.mark.parametrize(
376375
# "cohort_param,expected_result",
377376
# [
378377
# ({"min_cohort_size": 5}, "min_size"),
379378
# ({"max_cohort_size": 10}, "max_size"),
380379
# ({"cohort_size": 8}, "exact_size"),
381380
# ],
382-
#)
383-
#def test_cohort_filtering(cohort_param, expected_result):
381+
# )
382+
# def test_cohort_filtering(cohort_param, expected_result):
384383
# """Test cohort size filtering functionality with sample_query."""
385384
# ag3 = setup_ag3()
386385

@@ -423,7 +422,7 @@ def test_plot_haplotype_network_none(mocker):
423422
# pass # Acceptable if no cohorts meet exact size
424423

425424

426-
#def test_sample_query_functionality():
425+
# def test_sample_query_functionality():
427426
# """Test sample_query functionality."""
428427
# ag3 = setup_ag3()
429428

@@ -448,7 +447,7 @@ def test_plot_haplotype_network_none(mocker):
448447
# )
449448

450449

451-
#def test_invalid_parameters():
450+
# def test_invalid_parameters():
452451
# """Test error handling for invalid parameters."""
453452
# ag3 = setup_ag3()
454453

@@ -468,7 +467,7 @@ def test_plot_haplotype_network_none(mocker):
468467
# assert df.empty
469468

470469

471-
#def test_phenotype_binary_conversion():
470+
# def test_phenotype_binary_conversion():
472471
# """Test binary conversion of phenotype values (internal method)."""
473472
# ag3 = setup_ag3()
474473

@@ -514,7 +513,7 @@ def test_plot_haplotype_network_none(mocker):
514513
# assert np.isnan(invalid_binary.values[0])
515514

516515

517-
#def test_phenotype_sample_sets():
516+
# def test_phenotype_sample_sets():
518517
# """Test phenotype_sample_sets method for listing available sample sets with phenotype data."""
519518
# ag3 = setup_ag3()
520519

@@ -532,7 +531,7 @@ def test_plot_haplotype_network_none(mocker):
532531
# pytest.fail("No phenotype sample sets found to test.")
533532

534533

535-
#def test_phenotypes_with_snp_calls():
534+
# def test_phenotypes_with_snp_calls():
536535
# """Test phenotypes_with_snps method."""
537536
# ag3 = setup_ag3()
538537

@@ -556,7 +555,7 @@ def test_plot_haplotype_network_none(mocker):
556555
# assert all(ds["insecticide"].values == insecticide_query)
557556

558557

559-
#def test_phenotypes_with_haplotypes():
558+
# def test_phenotypes_with_haplotypes():
560559
# """Test phenotypes_with_haplotypes method."""
561560
# ag3 = setup_ag3()
562561

@@ -580,7 +579,7 @@ def test_plot_haplotype_network_none(mocker):
580579
# assert all(ds["insecticide"].values == insecticide_query)
581580

582581

583-
#def test_phenotype_data_only():
582+
# def test_phenotype_data_only():
584583
# """Test phenotype_data method returns only phenotype data (DataFrame), no genetic data."""
585584
# ag3 = setup_ag3()
586585

0 commit comments

Comments
 (0)