mocks.MockRedis

Here are the examples of the python api mocks.MockRedis taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

3 Examples 7

3 Source : conftest.py
with GNU General Public License v3.0
from teamsempo

def persistence_module(db_session):
    red = MockRedis()

    return SQLPersistenceInterface(
        red=red, session=db_session, first_block_hash='deadbeef01'
    )

@pytest.fixture(scope='function')

3 Source : conftest.py
with GNU General Public License v3.0
from teamsempo

def supervisor(persistence_module, processor):

    red = MockRedis()

    return TransactionSupervisor(red, persistence_module, processor)


@pytest.fixture(scope='function')

3 Source : conftest.py
with GNU General Public License v3.0
from teamsempo

def blockchain_sync(persistence_module, mock_w3):

    red = MockRedis()

    s = BlockchainSyncer(
        w3=mock_w3,
        red=red,
        persistence=persistence_module
    )

    return s


@pytest.fixture(scope='function')