Tarantool development patches archive
 help / color / mirror / Atom feed
* [Tarantool-patches] [PATCH v1] test: fix flaky sql/func-recreate
@ 2020-04-08  7:11 Alexander V. Tikhonov
  2020-04-10 14:18 ` Sergey Bronnikov
  0 siblings, 1 reply; 3+ messages in thread
From: Alexander V. Tikhonov @ 2020-04-08  7:11 UTC (permalink / raw)
  To: Oleg Piskunov, Sergey Bronnikov; +Cc: tarantool-patches

Found that time limit in function used for testing in sql/func-recreate
test not enough for some time. Fiber set next is too near the time
limit. Decided to increase the time limit of the function, anyway it
checks its value at the test.

Close #4384
---

Github: https://github.com/tarantool/tarantool/tree/avtikhon/gh-4384-increase-waitfor-time
Issue: https://github.com/tarantool/tarantool/issues/4384

 test/sql/func-recreate.result   | 6 +++---
 test/sql/func-recreate.test.lua | 2 +-
 test/sql/suite.ini              | 1 -
 3 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/test/sql/func-recreate.result b/test/sql/func-recreate.result
index 73fb03cc4..c28e2c071 100644
--- a/test/sql/func-recreate.result
+++ b/test/sql/func-recreate.result
@@ -18,7 +18,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
 ch = fiber.channel(1)
 ---
 ...
-_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
+_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
 ---
 ...
 fiber.sleep(0.1)
@@ -32,10 +32,10 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber')
 ch:get()
 ---
 - metadata:
-  - name: WAITFOR(0.2)
+  - name: WAITFOR(0.5)
     type: integer
   rows:
-  - [0.2]
+  - [0.5]
 ...
 box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
 ---
diff --git a/test/sql/func-recreate.test.lua b/test/sql/func-recreate.test.lua
index 753e9ca4d..fa480288f 100644
--- a/test/sql/func-recreate.test.lua
+++ b/test/sql/func-recreate.test.lua
@@ -8,7 +8,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
 
 ch = fiber.channel(1)
 
-_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
+_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
 fiber.sleep(0.1)
 
 box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
diff --git a/test/sql/suite.ini b/test/sql/suite.ini
index a8664c510..cc1d641a8 100644
--- a/test/sql/suite.ini
+++ b/test/sql/suite.ini
@@ -11,4 +11,3 @@ release_disabled = errinj.test.lua view_delayed_wal.test.lua sql-debug.test.lua
 disabled = sql-statN-index-drop.test.lua
 pretest_clean = True
 fragile = dll.test.lua           ; gh-4427
-          func-recreate.test.lua ; gh-4384
-- 
2.17.1

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Tarantool-patches] [PATCH v1] test: fix flaky sql/func-recreate
  2020-04-08  7:11 [Tarantool-patches] [PATCH v1] test: fix flaky sql/func-recreate Alexander V. Tikhonov
@ 2020-04-10 14:18 ` Sergey Bronnikov
  2020-04-13  9:29   ` Oleg Piskunov
  0 siblings, 1 reply; 3+ messages in thread
From: Sergey Bronnikov @ 2020-04-10 14:18 UTC (permalink / raw)
  To: Alexander V. Tikhonov; +Cc: Oleg Piskunov, tarantool-patches

LGTM

On 10:11 Wed 08 Apr , Alexander V. Tikhonov wrote:
> Found that time limit in function used for testing in sql/func-recreate
> test not enough for some time. Fiber set next is too near the time
> limit. Decided to increase the time limit of the function, anyway it
> checks its value at the test.
> 
> Close #4384
> ---
> 
> Github: https://github.com/tarantool/tarantool/tree/avtikhon/gh-4384-increase-waitfor-time
> Issue: https://github.com/tarantool/tarantool/issues/4384
> 
>  test/sql/func-recreate.result   | 6 +++---
>  test/sql/func-recreate.test.lua | 2 +-
>  test/sql/suite.ini              | 1 -
>  3 files changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/test/sql/func-recreate.result b/test/sql/func-recreate.result
> index 73fb03cc4..c28e2c071 100644
> --- a/test/sql/func-recreate.result
> +++ b/test/sql/func-recreate.result
> @@ -18,7 +18,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
>  ch = fiber.channel(1)
>  ---
>  ...
> -_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
> +_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
>  ---
>  ...
>  fiber.sleep(0.1)
> @@ -32,10 +32,10 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber')
>  ch:get()
>  ---
>  - metadata:
> -  - name: WAITFOR(0.2)
> +  - name: WAITFOR(0.5)
>      type: integer
>    rows:
> -  - [0.2]
> +  - [0.5]
>  ...
>  box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
>  ---
> diff --git a/test/sql/func-recreate.test.lua b/test/sql/func-recreate.test.lua
> index 753e9ca4d..fa480288f 100644
> --- a/test/sql/func-recreate.test.lua
> +++ b/test/sql/func-recreate.test.lua
> @@ -8,7 +8,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
>  
>  ch = fiber.channel(1)
>  
> -_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
> +_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
>  fiber.sleep(0.1)
>  
>  box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
> diff --git a/test/sql/suite.ini b/test/sql/suite.ini
> index a8664c510..cc1d641a8 100644
> --- a/test/sql/suite.ini
> +++ b/test/sql/suite.ini
> @@ -11,4 +11,3 @@ release_disabled = errinj.test.lua view_delayed_wal.test.lua sql-debug.test.lua
>  disabled = sql-statN-index-drop.test.lua
>  pretest_clean = True
>  fragile = dll.test.lua           ; gh-4427
> -          func-recreate.test.lua ; gh-4384
> -- 
> 2.17.1
> 

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Tarantool-patches] [PATCH v1] test: fix flaky sql/func-recreate
  2020-04-10 14:18 ` Sergey Bronnikov
@ 2020-04-13  9:29   ` Oleg Piskunov
  0 siblings, 0 replies; 3+ messages in thread
From: Oleg Piskunov @ 2020-04-13  9:29 UTC (permalink / raw)
  To: Alexander Turenko; +Cc: tarantool-patches

[-- Attachment #1: Type: text/plain, Size: 2748 bytes --]


LGTM
  
>Пятница, 10 апреля 2020, 17:18 +03:00 от Sergey Bronnikov <sergeyb@tarantool.org>:
> 
>LGTM
>
>On 10:11 Wed 08 Apr , Alexander V. Tikhonov wrote:
>> Found that time limit in function used for testing in sql/func-recreate
>> test not enough for some time. Fiber set next is too near the time
>> limit. Decided to increase the time limit of the function, anyway it
>> checks its value at the test.
>>
>> Close #4384
>> ---
>>
>> Github:  https://github.com/tarantool/tarantool/tree/avtikhon/gh-4384-increase-waitfor-time
>> Issue:  https://github.com/tarantool/tarantool/issues/4384
>>
>> test/sql/func-recreate.result | 6 +++---
>> test/sql/func-recreate.test.lua | 2 +-
>> test/sql/suite.ini | 1 -
>> 3 files changed, 4 insertions(+), 5 deletions(-)
>>
>> diff --git a/test/sql/func-recreate.result b/test/sql/func-recreate.result
>> index 73fb03cc4..c28e2c071 100644
>> --- a/test/sql/func-recreate.result
>> +++ b/test/sql/func-recreate.result
>> @@ -18,7 +18,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
>> ch = fiber.channel(1)
>> ---
>> ...
>> -_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
>> +_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
>> ---
>> ...
>> fiber.sleep(0.1)
>> @@ -32,10 +32,10 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber')
>> ch:get()
>> ---
>> - metadata:
>> - - name: WAITFOR(0.2)
>> + - name: WAITFOR(0.5)
>> type: integer
>> rows:
>> - - [0.2]
>> + - [0.5]
>> ...
>> box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
>> ---
>> diff --git a/test/sql/func-recreate.test.lua b/test/sql/func-recreate.test.lua
>> index 753e9ca4d..fa480288f 100644
>> --- a/test/sql/func-recreate.test.lua
>> +++ b/test/sql/func-recreate.test.lua
>> @@ -8,7 +8,7 @@ box.internal.sql_create_function('WAITFOR', 'INT', function (n) fiber.sleep(n) r
>>
>> ch = fiber.channel(1)
>>
>> -_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.2)')) end)
>> +_ = fiber.create(function () ch:put(box.execute('select WAITFOR(0.5)')) end)
>> fiber.sleep(0.1)
>>
>> box.internal.sql_create_function('WAITFOR', 'INT', function (n) require('fiber').sleep(n) return n end)
>> diff --git a/test/sql/suite.ini b/test/sql/suite.ini
>> index a8664c510..cc1d641a8 100644
>> --- a/test/sql/suite.ini
>> +++ b/test/sql/suite.ini
>> @@ -11,4 +11,3 @@ release_disabled = errinj.test.lua view_delayed_wal.test.lua sql-debug.test.lua
>> disabled = sql-statN-index-drop.test.lua
>> pretest_clean = True
>> fragile = dll.test.lua ; gh-4427
>> - func-recreate.test.lua ; gh-4384
>> --
>> 2.17.1
>>
>--
>sergeyb@ 
 
 
--
Oleg Piskunov
 

[-- Attachment #2: Type: text/html, Size: 3749 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-04-13  9:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-08  7:11 [Tarantool-patches] [PATCH v1] test: fix flaky sql/func-recreate Alexander V. Tikhonov
2020-04-10 14:18 ` Sergey Bronnikov
2020-04-13  9:29   ` Oleg Piskunov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox