fix: main nodes setup to 2 node cl setup

This commit is contained in:
Roman 2025-01-21 14:55:26 +08:00
parent 7cdcc0d084
commit d021e52efd
No known key found for this signature in database
GPG Key ID: B8FE070B54E11B75
3 changed files with 4 additions and 5 deletions

View File

@ -16,7 +16,7 @@ class StepsCommon:
self.main_nodes = []
@pytest.fixture(scope="function")
def setup_main_nodes(self, request):
def setup_2_node_cluster(self, request):
logger.debug(f"Running fixture setup: {inspect.currentframe().f_code.co_name}")
self.node1 = NomosNode(CFGSYNC, "cfgsync")
self.node2 = NomosNode(NOMOS, "nomos_node_0")

View File

@ -7,14 +7,13 @@ from src.test_data import DATA_TO_DISPERSE
logger = get_custom_logger(__name__)
@pytest.mark.usefixtures("setup_main_nodes")
class TestDataIntegrity(StepsDataAvailability):
main_nodes = []
def test_da_identify_retrieve_missing_columns(self):
for node in self.main_nodes:
print(node)
self.disperse_data(DATA_TO_DISPERSE[0], [0] * 31 + [1], [0] * 8)
@pytest.mark.usefixtures("setup_2_node_cluster")
def test_da_sampling_determines_data_presence(self):
self.disperse_data(DATA_TO_DISPERSE[0], [0] * 31 + [1], [0] * 8)
received_data = self.get_data_range([0] * 31 + [1], [0] * 8, [0] * 7 + [5])

View File

@ -9,6 +9,6 @@ logger = get_custom_logger(__name__)
class Test2NodeClAlive(StepsCommon):
@pytest.mark.usefixtures("setup_main_nodes")
@pytest.mark.usefixtures("setup_2_node_cluster")
def test_cluster_start(self):
logger.debug("Two node cluster started successfully!")