From 1e15c14b1fb952556b506d99c559cba644e9f391 Mon Sep 17 00:00:00 2001 From: Georgy Moiseev Date: Mon, 22 Jan 2024 18:13:30 +0300 Subject: [PATCH] test: refer to storage server by id Index alias provide stable info on instance nature, yet servers list index doesn't. Part of #412 Part of #415 --- test/integration/borders_test.lua | 2 +- test/integration/custom_bucket_id_test.lua | 2 +- test/integration/pairs_test.lua | 2 +- test/integration/select_readview_test.lua | 2 +- test/integration/select_test.lua | 2 +- test/integration/truncate_test.lua | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/integration/borders_test.lua b/test/integration/borders_test.lua index 511b4662..286a973e 100644 --- a/test/integration/borders_test.lua +++ b/test/integration/borders_test.lua @@ -12,7 +12,7 @@ local pgroup = t.group('borders', helpers.backend_matrix({ pgroup.before_all(function(g) helpers.start_default_cluster(g, 'srv_select') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() end) pgroup.after_all(function(g) diff --git a/test/integration/custom_bucket_id_test.lua b/test/integration/custom_bucket_id_test.lua index e4063484..c0338d5d 100644 --- a/test/integration/custom_bucket_id_test.lua +++ b/test/integration/custom_bucket_id_test.lua @@ -12,7 +12,7 @@ local pgroup = t.group('custom_bucket_id', helpers.backend_matrix({ pgroup.before_all(function(g) helpers.start_default_cluster(g, 'srv_simple_operations') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() end) pgroup.after_all(function(g) diff --git a/test/integration/pairs_test.lua b/test/integration/pairs_test.lua index 9c3c2bd5..f0b832f7 100644 --- a/test/integration/pairs_test.lua +++ b/test/integration/pairs_test.lua @@ -13,7 +13,7 @@ local pgroup = t.group('pairs', helpers.backend_matrix({ pgroup.before_all(function(g) helpers.start_default_cluster(g, 'srv_select') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() g.cluster.main_server.net_box:eval([[ require('crud').cfg{ stats = true } diff --git a/test/integration/select_readview_test.lua b/test/integration/select_readview_test.lua index 87a5b7d6..a1a796d2 100644 --- a/test/integration/select_readview_test.lua +++ b/test/integration/select_readview_test.lua @@ -16,7 +16,7 @@ local pgroup = t.group('select_readview', helpers.backend_matrix({ local function init_cluster(g) helpers.start_default_cluster(g, 'srv_select') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() g.router = helpers.get_router(g.cluster, g.params.backend) g.router.net_box:eval([[ diff --git a/test/integration/select_test.lua b/test/integration/select_test.lua index 9373ac64..e8807f28 100644 --- a/test/integration/select_test.lua +++ b/test/integration/select_test.lua @@ -14,7 +14,7 @@ local pgroup = t.group('select', helpers.backend_matrix({ pgroup.before_all(function(g) helpers.start_default_cluster(g, 'srv_select') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() g.router = helpers.get_router(g.cluster, g.params.backend) g.router.net_box:eval([[ diff --git a/test/integration/truncate_test.lua b/test/integration/truncate_test.lua index 873427c7..3d5dcc18 100644 --- a/test/integration/truncate_test.lua +++ b/test/integration/truncate_test.lua @@ -10,7 +10,7 @@ local pgroup = t.group('truncate', helpers.backend_matrix({ pgroup.before_all(function(g) helpers.start_default_cluster(g, 'srv_select') - g.space_format = g.cluster.servers[2].net_box.space.customers:format() + g.space_format = g.cluster:server('s1-master').net_box.space.customers:format() end) pgroup.after_all(function(g)