From: "Alexander V. Tikhonov" <avtikhon@tarantool.org> To: Kirill Yukhin <kyukhin@tarantool.org> Cc: Sergei Voronezhskii <sergw@tarantool.org>, tarantool-patches@dev.tarantool.org Subject: [Tarantool-patches] [PATCH v1 10/12] test: put require in proper places Date: Tue, 26 Nov 2019 09:21:46 +0300 [thread overview] Message-ID: <31a85b0452751f35fdee03d334df5e366677486c.1574749278.git.avtikhon@tarantool.org> (raw) In-Reply-To: <1c42ad20160f47d942cab405ce9896d6d31cc05f.1574749278.git.avtikhon@tarantool.org> In-Reply-To: <1c42ad20160f47d942cab405ce9896d6d31cc05f.1574749278.git.avtikhon@tarantool.org> From: Sergei Voronezhskii <sergw@tarantool.org> * put `require('fiber')` after each switch server command, because sometimes got 'fiber' not defined error * use `require('fio')` after `require('test_run').new()`, because sometimes got 'fio' not defined error Part of #2436, #3232 (cherry picked from commit d2f28afaf7f045687df191cd93c935dcc442811b) --- test/replication/catch.test.lua | 1 - test/replication/gc.result | 6 +++--- test/replication/gc.test.lua | 2 +- test/replication/on_replace.result | 3 +++ test/replication/on_replace.test.lua | 1 + 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/test/replication/catch.test.lua b/test/replication/catch.test.lua index d5de88642..7a531df39 100644 --- a/test/replication/catch.test.lua +++ b/test/replication/catch.test.lua @@ -2,7 +2,6 @@ env = require('test_run') test_run = env.new() engine = test_run:get_cfg('engine') - net_box = require('net.box') errinj = box.error.injection diff --git a/test/replication/gc.result b/test/replication/gc.result index 5b44284bf..cbdeffb11 100644 --- a/test/replication/gc.result +++ b/test/replication/gc.result @@ -1,6 +1,3 @@ -fio = require 'fio' ---- -... test_run = require('test_run').new() --- ... @@ -13,6 +10,9 @@ replica_set = require('fast_replica') fiber = require('fiber') --- ... +fio = require('fio') +--- +... test_run:cleanup_cluster() --- ... diff --git a/test/replication/gc.test.lua b/test/replication/gc.test.lua index fee1fe968..4710fd9e3 100644 --- a/test/replication/gc.test.lua +++ b/test/replication/gc.test.lua @@ -1,8 +1,8 @@ -fio = require 'fio' test_run = require('test_run').new() engine = test_run:get_cfg('engine') replica_set = require('fast_replica') fiber = require('fiber') +fio = require('fio') test_run:cleanup_cluster() test_run:cmd("create server replica with rpl_master=default, script='replication/replica.lua'") diff --git a/test/replication/on_replace.result b/test/replication/on_replace.result index 8fef8fb14..2e95b90ea 100644 --- a/test/replication/on_replace.result +++ b/test/replication/on_replace.result @@ -63,6 +63,9 @@ test_run:cmd("switch replica") --- - true ... +fiber = require('fiber') +--- +... while box.space.test:count() < 2 do fiber.sleep(0.01) end --- ... diff --git a/test/replication/on_replace.test.lua b/test/replication/on_replace.test.lua index 23a3313b5..e34832103 100644 --- a/test/replication/on_replace.test.lua +++ b/test/replication/on_replace.test.lua @@ -26,6 +26,7 @@ session_type test_run:cmd("switch default") box.space.test:insert{2} test_run:cmd("switch replica") +fiber = require('fiber') while box.space.test:count() < 2 do fiber.sleep(0.01) end -- -- applier -- 2.17.1
next prev parent reply other threads:[~2019-11-26 6:22 UTC|newest] Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-11-26 6:21 [Tarantool-patches] [PATCH v1 01/12] test: enable parallel mode for xlog tests Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 02/12] test: enable parallel run for long test suites Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 03/12] test: replication parallel mode on Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 04/12] test: enable cleaning of a test environment Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 05/12] test: allow to run replication/misc multiple times Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 06/12] test: increase timeouts in replication/errinj Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 07/12] test: wait for xlog/snap/log file changes Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 08/12] test: use wait_cond to check follow status Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 09/12] test: increase timeouts in replication/misc Alexander V. Tikhonov 2019-11-26 6:21 ` Alexander V. Tikhonov [this message] 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 11/12] test: fix replication/gc flaky failures Alexander V. Tikhonov 2019-11-26 6:21 ` [Tarantool-patches] [PATCH v1 12/12] test: errinj for pause relay_send Alexander V. Tikhonov 2019-11-26 6:54 ` [Tarantool-patches] [PATCH v1 01/12] test: enable parallel mode for xlog tests Kirill Yukhin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=31a85b0452751f35fdee03d334df5e366677486c.1574749278.git.avtikhon@tarantool.org \ --to=avtikhon@tarantool.org \ --cc=kyukhin@tarantool.org \ --cc=sergw@tarantool.org \ --cc=tarantool-patches@dev.tarantool.org \ --subject='Re: [Tarantool-patches] [PATCH v1 10/12] test: put require in proper places' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox