Skip to content

Commit

Permalink
more tests for 3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
sierra-moxon committed May 15, 2024
1 parent 60c50c3 commit 83f35a8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/test_gpiwriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import pytest


@pytest.mark.parametrize("gpad_gpi_output_version", ["2.0", "1.2"])
@pytest.mark.parametrize("gpad_gpi_output_version", ["2.0", "1.2"])
def test_produce_gpi(gpad_gpi_output_version):
# Base path relative to this script
Expand All @@ -31,13 +32,13 @@ def test_produce_gpi(gpad_gpi_output_version):

# Verify the contents of the GPI file
p = entityparser.GpiParser()
with output_gpi_path.open() as f:
with open(output_gpi_path, "r") as f:
assert p.parse(f) is not None, "The GPI file could not be parsed."
f.seek(0) # Reset file pointer to the beginning
results = p.parse(f)
assert len(results) > 5, "The GPI file should have about 9 unique genes from ~ 90 associations in the GAF file."

with output_gpi_path.open() as f:
with open(output_gpi_path, "r") as f:
lines = f.readlines()

assert len(lines) > 0, "The GPI file should not be empty."
Expand Down

0 comments on commit 83f35a8

Please sign in to comment.