Skip to content

Commit

Permalink
Skip Redis tests on OSX
Browse files Browse the repository at this point in the history
  • Loading branch information
WardLT committed Jul 31, 2023
1 parent 3d6d547 commit a56e637
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
9 changes: 8 additions & 1 deletion colmena/queue/tests/test_queues.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Tests across different queue implementations"""
from multiprocessing import Pool
from shutil import which

from pytest import fixture, raises, mark

Expand All @@ -8,8 +9,14 @@
from colmena.queue.python import PipeQueues
from colmena.queue.redis import RedisQueues

# Determine which classes to test
to_test = [PipeQueues]
has_redis = which('redis-server') is not None
if has_redis:
to_test.append(RedisQueues)

@fixture(params=[PipeQueues, RedisQueues])

@fixture(params=to_test)
def queue(request) -> ColmenaQueues:
return request.param(['a', 'b'])

Expand Down
6 changes: 3 additions & 3 deletions colmena/task_server/tests/test_parsl.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

from parsl import HighThroughputExecutor
from parsl.config import Config
from proxystore.connectors.file import FileConnector
from pytest import fixture, mark

from proxystore.connectors.redis import RedisConnector
from proxystore.store import Store
from proxystore.store import register_store
from proxystore.store import unregister_store
Expand Down Expand Up @@ -48,8 +48,8 @@ def config(tmpdir):

# Make a proxy store for larger objects
@fixture(scope='module')
def store():
connector = RedisConnector(hostname='localhost', port=6379)
def store(tmp_path):
connector = FileConnector(store_dir=str(tmp_path))
with Store('store', connector=connector, metrics=True) as store:
register_store(store)
yield store
Expand Down

0 comments on commit a56e637

Please sign in to comment.