Skip to content

Commit

Permalink
Fix gpt and cellxgene setup in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lauraluebbert committed May 15, 2023
1 parent 9c4afd7 commit e6aa22f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion gget/gget_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ def setup(module):
# Install pdbfixer version compatible with openmm v7.5.1
PDBFIXER_VERSION = "v1.7"
except:
PDBFIXER_VERSION = "main"
PDBFIXER_VERSION = "1.8.1" # Latest: 1.9

command = f"""
git clone -q --branch {PDBFIXER_VERSION} {PDBFIXER_GIT_REPO} {pdbfixer_folder} \
Expand Down
6 changes: 3 additions & 3 deletions tests/test_cellxgene.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@
import pandas as pd
import json
from gget.gget_cellxgene import cellxgene

# Install cellxgene module specific dependencies
from gget.gget_setup import setup
setup("cellxgene")

# Load dictionary containing arguments and expected results
with open("./tests/fixtures/test_cellxgene.json") as json_file:
Expand Down Expand Up @@ -40,6 +37,9 @@ def repr_dict(adata):


class TestCellxgene(unittest.TestCase):
def install_dependencies(self):
setup("cellxgene")

def test_cellxgene_adata(self):
test = "test1"
expected_result = cellxgene_dict[test]["expected_result"]
Expand Down
6 changes: 3 additions & 3 deletions tests/test_gpt.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import unittest
from unittest.mock import patch
from gget.gget_gpt import gpt

# Install gpt module specific dependencies
from gget.gget_setup import setup
setup("gpt")


class TestGpt(unittest.TestCase):
def install_dependencies(self):
setup("gpt")

@patch("openai.ChatCompletion.create")
def test_gpt(self, mock_create):
# Mock the response from the API
Expand Down

0 comments on commit e6aa22f

Please sign in to comment.