mirror of https://github.com/nucypher/nucypher.git
Create bob_control fixture
parent
71d1d9f709
commit
7882ed6114
|
@ -0,0 +1,6 @@
|
|||
from flask import Flask, request, Response
|
||||
|
||||
def make_bob_control(drone_bob: 'Bob'):
|
||||
bob_control = Flask('bob-control')
|
||||
|
||||
return bob_control
|
|
@ -38,6 +38,7 @@ from nucypher.keystore import keystore
|
|||
from nucypher.keystore.db import Base
|
||||
from nucypher.keystore.keypairs import SigningKeypair
|
||||
from nucypher.network.character_control.alice_control import make_alice_control
|
||||
from nucypher.network.character_control.bob_control import make_bob_control
|
||||
from nucypher.utilities.sandbox.blockchain import TesterBlockchain, token_airdrop
|
||||
from nucypher.utilities.sandbox.constants import (NUMBER_OF_URSULAS_IN_DEVELOPMENT_NETWORK,
|
||||
DEVELOPMENT_TOKEN_AIRDROP_AMOUNT, MOCK_URSULA_STARTING_PORT,
|
||||
|
@ -333,6 +334,15 @@ def alice_control(federated_alice):
|
|||
yield alice_control.test_client()
|
||||
|
||||
|
||||
@pytest.fixture(scope='module')
|
||||
def bob_control(federated_bob):
|
||||
federated_bob.start_learning_loop(now=True)
|
||||
bob_control = make_bob_control(federated_bob)
|
||||
bob_control.config['DEBUG'] = True
|
||||
bob_control.config['TESTING'] = True
|
||||
yield bob_control.test_client()
|
||||
|
||||
|
||||
#
|
||||
# Blockchain
|
||||
#
|
||||
|
|
Loading…
Reference in New Issue