mirror of
https://github.com/logos-blockchain/logos-blockchain-e2e-tests.git
synced 2026-01-02 13:13:08 +00:00
fix: update da_identify_retrieve_missing_columns to cycle through all nodes
This commit is contained in:
parent
442a94551d
commit
b455b57bf9
@ -123,6 +123,9 @@ class NomosNode:
|
||||
def node_type(self):
|
||||
return self._node_type
|
||||
|
||||
def name(self):
|
||||
return self._container_name
|
||||
|
||||
def check_nomos_log_errors(self, whitelist=None):
|
||||
keywords = LOG_ERROR_KEYWORDS
|
||||
|
||||
|
||||
@ -19,14 +19,20 @@ class TestDataIntegrity(StepsDataAvailability):
|
||||
def test_da_identify_retrieve_missing_columns(self):
|
||||
self.disperse_data(DATA_TO_DISPERSE[1], to_app_id(1), to_index(0))
|
||||
delay(5)
|
||||
# Select one target node at random to get blob data for 1/2 columns
|
||||
selected_node = self.main_nodes[random.randint(1, 3)]
|
||||
rcv_data = self.get_data_range(selected_node, to_app_id(1), to_index(0), to_index(5))
|
||||
rcv_data_json = json.dumps(rcv_data)
|
||||
test_results = []
|
||||
# Iterate through standard nodes to get blob data for 1/2 columns
|
||||
for node in self.main_nodes[1:4]:
|
||||
rcv_data = self.get_data_range(node, to_app_id(1), to_index(0), to_index(5))
|
||||
rcv_data_json = json.dumps(rcv_data)
|
||||
|
||||
reconstructed_data = NomosCli(command="reconstruct").run(input_values=[rcv_data_json])
|
||||
reconstructed_data = NomosCli(command="reconstruct").run(input_values=[rcv_data_json])
|
||||
|
||||
assert DATA_TO_DISPERSE[1] == reconstructed_data, "Reconstructed data are not same with original data"
|
||||
if DATA_TO_DISPERSE[1] == reconstructed_data:
|
||||
test_results.append(node.name())
|
||||
|
||||
assert len(test_results) > 0, "Dispersed data were not received by any node"
|
||||
|
||||
logger.info(f"Dispersed data received by : {test_results}")
|
||||
|
||||
@pytest.mark.usefixtures("setup_2_node_cluster")
|
||||
def test_da_sampling_determines_data_presence(self):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user