Skip to content

Commit

Permalink
chore: resolve/remove skipped tests (#1236)
Browse files Browse the repository at this point in the history
Co-authored-by: Evan Molinelli <[email protected]>
  • Loading branch information
ejmolinelli and Evan Molinelli authored Jan 31, 2025
1 parent 0387a19 commit 2aa2036
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 57 deletions.
6 changes: 0 additions & 6 deletions cellxgene_schema_cli/tests/test_map_species.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,6 @@ def validator_with_adata(zebrafish_adata):
return validator


@pytest.mark.skip(
reason="Skipping this test as the schema its based on has changed and this command is being deprecated"
)
def test_map_species__valid_output(validator_with_adata):
with TemporaryDirectory() as tmp:
input_file = tmp + "input.h5ad"
Expand Down Expand Up @@ -109,9 +106,6 @@ def test_map_species_log_output_no_match(zebrafish_adata, caplog):
assert "ZFA:0000047 has no closest match for UBERON in its ancestry tree." in caplog.text


@pytest.mark.skip(
reason="Skipping this test as the schema its based on has changed and this command is being deprecated"
)
def test_map_species__with_existing_cols(validator_with_adata):
obs = validator_with_adata.adata.obs
obs["cell_type_ontology_term_id"] = ""
Expand Down
51 changes: 0 additions & 51 deletions cellxgene_schema_cli/tests/test_schema_compliance.py
Original file line number Diff line number Diff line change
Expand Up @@ -2913,23 +2913,6 @@ def test_organism_cell_type_ontology_term_id__visium_in_tissue_0_invalid(
in validator.errors[0]
)

@pytest.mark.skip(
reason="Skipping this test to unblock downstream multispecies work. TODO: fix before 5.3.0 release"
)
def test_cell_type_ontology_term_id__visium_in_tissue_0__na(self, validator_with_visium_zebrafish_adata):
validator = validator_with_visium_zebrafish_adata
error_message = (
"ERROR: 'na' in 'cell_type_ontology_term_id' is not a valid ontology term id of 'ZFA'. "
"When 'organism_ontology_term_id' is 'NCBITaxon:7955' (Danio rerio), "
"'cell_type_ontology_term_id' MUST be a descendant term id of 'ZFA:0009000' (cell)."
)
obs = validator.adata.obs
obs.loc[obs.index[0], "in_tissue"] = 0
obs.loc[obs.index[0], "cell_type_ontology_term_id"] = "na"
validator.validate_adata()
# Passes visium check but fails cell_type_ontology_term_id check
assert validator.errors == [error_message]

@pytest.mark.parametrize(
"tissue_ontology_term_id",
[
Expand Down Expand Up @@ -3105,23 +3088,6 @@ def test_organism_cell_type_ontology_term_id__visium_in_tissue_0_invalid(
in validator.errors[0]
)

@pytest.mark.skip(
reason="Skipping this test to unblock downstream multispecies work. TODO: fix before 5.3.0 release"
)
def test_cell_type_ontology_term_id__visium_in_tissue_0__na(self, validator_with_visium_fruitfly_adata):
validator = validator_with_visium_fruitfly_adata
error_message = (
"ERROR: 'na' in 'cell_type_ontology_term_id' is not a valid ontology term id of 'FBbt'. "
"When 'organism_ontology_term_id' is 'NCBITaxon:7227' (Drosophila melanogaster), "
"'cell_type_ontology_term_id' MUST be a descendant term id of 'FBbt:00007002' (cell)."
)
obs = validator.adata.obs
obs.loc[obs.index[0], "in_tissue"] = 0
obs.loc[obs.index[0], "cell_type_ontology_term_id"] = "na"
validator.validate_adata()
# Passes visium check but fails cell_type_ontology_term_id check
assert validator.errors == [error_message]

@pytest.mark.parametrize(
"tissue_ontology_term_id",
[
Expand Down Expand Up @@ -3303,23 +3269,6 @@ def test_organism_cell_type_ontology_term_id__visium_in_tissue_0_invalid(
in validator.errors[0]
)

@pytest.mark.skip(
reason="Skipping this test to unblock downstream multispecies work. TODO: fix before 5.3.0 release"
)
def test_organism_cell_type_ontology_term_id__visium_in_tissue_0__na(self, validator_with_visium_roundworm_adata):
validator = validator_with_visium_roundworm_adata
error_message = (
"ERROR: 'na' in 'organism_cell_type_ontology_term_id' is not a valid ontology term id of 'WBbt'. "
"When 'organism_ontology_term_id' is 'NCBITaxon:6239' (Caenorhabditis elegans), "
"'organism_cell_type_ontology_term_id' MUST be a descendant term id of 'WBbt:0004017' (cell)."
)
obs = validator.adata.obs
obs.loc[obs.index[0], "in_tissue"] = 0
obs.loc[obs.index[0], "organism_cell_type_ontology_term_id"] = "na"
validator.validate_adata()
# Passes visium check but fails organism_cell_type_ontology_term_id check
assert validator.errors == [error_message]

@pytest.mark.parametrize(
"tissue_ontology_term_id",
[
Expand Down

0 comments on commit 2aa2036

Please sign in to comment.