From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp33.i.mail.ru (smtp33.i.mail.ru [94.100.177.93]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id DF80743D678 for ; Wed, 23 Oct 2019 00:15:06 +0300 (MSK) References: <52e7822bbcd802528d448c15ce9e9fbe4479c73a.1570546695.git.sergepetrenko@tarantool.org> From: Vladislav Shpilevoy Message-ID: <559a4e59-1a36-7b74-e3b8-81d1e5876915@tarantool.org> Date: Tue, 22 Oct 2019 23:20:23 +0200 MIME-Version: 1.0 In-Reply-To: <52e7822bbcd802528d448c15ce9e9fbe4479c73a.1570546695.git.sergepetrenko@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Tarantool-patches] [tarantool-patches] [PATCH v2 1/2] test: modify swim_run_test to break event loop List-Id: Tarantool development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: tarantool-patches@freelists.org, Serge Petrenko , georgy@tarantool.org, tarantool-patches@dev.tarantool.org Hi! Thanks for the patch! On 08/10/2019 17:03, Serge Petrenko wrote: > Add a wrapper function around swim test passed to swim_run_test which > breaks from default cord event loop. Otherwise we will hang indefinitely > in ev_run in case there is a started watcher. But why? The loop runs only until there are fibers to run. By design of these tests, after they are done, there should be not a single fiber nor a watcher, and the loop is finished without a break. This is why the tests pass without this patch. So what is a purpose of this commit? It does not change anything except that it may mask some errors. Because if the SWIM unit tests would hang without a break, then something is wrong. I caught several bugs in SWIM via this. If fiber.top() somehow interferes, then probably you could turn it off for this test? I just don't want to miss possible SWIM bugs. > > Found during work on #2694 > --- > test/unit/swim_test_utils.c | 14 +++++++++++++- > 1 file changed, 13 insertions(+), 1 deletion(-) >