From 5ffd3ccc8e00dee4a1c44dfed5b550da15ca8122 Mon Sep 17 00:00:00 2001 From: Pavel Emelyanov Date: Thu, 9 Apr 2026 20:29:59 +0300 Subject: [PATCH] test_backup: Remove create_ks_and_cf helper Test Remove the create_ks_and_cf() helper function and its now-unused import of format_tuples(). All callers have been converted to use the new async patterns with new_test_keyspace() and cql.run_async(). Signed-off-by: Pavel Emelyanov Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- test/cluster/object_store/test_backup.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/test/cluster/object_store/test_backup.py b/test/cluster/object_store/test_backup.py index 697694cd7c..f04acaff63 100644 --- a/test/cluster/object_store/test_backup.py +++ b/test/cluster/object_store/test_backup.py @@ -13,7 +13,6 @@ import time import random from test.pylib.manager_client import ManagerClient, ServerInfo -from test.cluster.object_store.conftest import format_tuples from test.cluster.util import wait_for_cql_and_get_hosts, get_replication, new_test_keyspace from test.pylib.rest_client import read_barrier from test.pylib.util import unique_name, wait_all @@ -26,22 +25,6 @@ import statistics logger = logging.getLogger(__name__) -def create_ks_and_cf(cql): - ks = 'test_ks' - cf = 'test_cf' - - replication_opts = format_tuples({'class': 'NetworkTopologyStrategy', 'replication_factor': '1'}) - cql.execute((f"CREATE KEYSPACE {ks} WITH REPLICATION = {replication_opts};")) - cql.execute(f"CREATE TABLE {ks}.{cf} ( name text primary key, value text );") - - rows = [('0', 'zero'), - ('1', 'one'), - ('2', 'two')] - for row in rows: - cql_fmt = "INSERT INTO {}.{} ( name, value ) VALUES ('{}', '{}');" - cql.execute(cql_fmt.format(ks, cf, *row)) - - return ks, cf async def take_snapshot(ks, servers, manager, logger):