From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 36CEE586688; Mon, 9 Dec 2024 14:12:25 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 36CEE586688 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1733742745; bh=BYJpp+SVX4nWLVymEzynVWYwCvEaptLqb6a7ysLTdQ0=; h=Date:To:Cc:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=KDOpq84sjaIaWiELDzKaSyl21ZGUJAZTjUmlcJ5qV79go/B5/Qdb41IJAbiQ8Hy/P RfsoCg3lO7zCZwBiK7oxiPjeAL5+N1Cdw6ayb+f8CqE1SCHxjpSlVvnwGZixhhRQSe uCX+2bFEDtKVAeKzS3KnkhXDZWedgXhY6MLZEUbU= Received: from send241.i.mail.ru (send241.i.mail.ru [95.163.59.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 4176D586688 for ; Mon, 9 Dec 2024 14:12:23 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 4176D586688 Received: by exim-smtp-fb95f984f-gd4cq with esmtpa (envelope-from ) id 1tKbgc-000000001bn-1jRB; Mon, 09 Dec 2024 14:12:22 +0300 Content-Type: multipart/alternative; boundary="------------dhztB0fTDOIbJ0roZ2nxHmxe" Message-ID: Date: Mon, 9 Dec 2024 14:12:22 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: Sergey Kaplun , Maxim Kokryashkin Cc: tarantool-patches@dev.tarantool.org References: <6ff7e9ab8ba9441cc6c47be08f713838969c0e39.1733739230.git.skaplun@tarantool.org> Content-Language: en-US In-Reply-To: <6ff7e9ab8ba9441cc6c47be08f713838969c0e39.1733739230.git.skaplun@tarantool.org> X-Mailru-Src: smtp X-4EC0790: 10 X-7564579A: 78E4E2B564C1792B X-77F55803: 4F1203BC0FB41BD9008082F162C500070414C36455464A53EC9A59F2D1B9AD63182A05F538085040F1EF3475DC49D1773DE06ABAFEAF6705C722208B2DA50A4A26B6B34209C71468AF5C6C36E0A87868 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7F1942E6D70B4A2F0EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006377CC130305260E47D8638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D806DB8EA370B030E7B379B6F3E133655502271B93E35E71E2CC7F00164DA146DAFE8445B8C89999728AA50765F79006375FFD5C25497261569FA2833FD35BB23D2EF20D2F80756B5F868A13BD56FB6657A471835C12D1D977725E5C173C3A84C3BCA4DA3BE1BC1572CC7F00164DA146DA6F5DAA56C3B73B237318B6A418E8EAB8D32BA5DBAC0009BE9E8FC8737B5C2249A496649CD2B9676276E601842F6C81A12EF20D2F80756B5FB606B96278B59C4276E601842F6C81A127C277FBC8AE2E8BA0F45A697F502CAD3AA81AA40904B5D99C9F4D5AE37F343AD1F44FA8B9022EA23BBE47FD9DD3FB595F5C1EE8F4F765FC2EE5AD8F952D28FBE2021AF6380DFAD18AA50765F7900637B8FA30D9455089A722CA9DD8327EE4930A3850AC1BE2E7356A58BF81F659395FC4224003CC83647689D4C264860C145E X-C1DE0DAB: 0D63561A33F958A562049869EF907AEB5002B1117B3ED6961972CE30B8D209F3406406D89DD9EB8A823CB91A9FED034534781492E4B8EEAD9CFA8CFAC159CE19BDAD6C7F3747799A X-C8649E89: 1C3962B70DF3F0ADE00A9FD3E00BEEDF3FED46C3ACD6F73ED3581295AF09D3DF87807E0823442EA2ED31085941D9CD0AF7F820E7B07EA4CF5AADB65423A3A25F24E6A9D6A2FB541600F44CD5C768B58206179335373FB2E83D7E4ABC8EFFEBBE5C69F0120C2109DFAC695E7984281AD568E1E3FDCF8FA7D0C95A0E1C6516B3625F4332CA8FE04980913E6812662D5F2AB9AF64DB4688768036DF5FE9C0001AF333F2C28C22F508233FCF178C6DD14203 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojBv0bg8QSzYRBNGUz3WXW1Q== X-Mailru-Sender: 520A125C2F17F0B1E52FEF5D219D6140FCF304A5730E2A4D9487ABAC94A94B54D5652C79CB0C47580152A3D17938EB451EB5A0BCEC6A560B3DDE9B364B0DF289BE2DA36745F2EEB5CEBA01FB949A1F1EEAB4BC95F72C04283CDA0F3B3F5B9367 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v2 luajit 1/2] test: support number value of tag in LuaJIT-tests X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Sergey Bronnikov via Tarantool-patches Reply-To: Sergey Bronnikov Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" This is a multi-part message in MIME format. --------------dhztB0fTDOIbJ0roZ2nxHmxe Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hi, Sergey, thanks for the pacth! LGTM On 09.12.2024 13:16, Sergey Kaplun wrote: > The LuaJIT-tests suite lacks the ability to specify tags with custom > values. This patch adds the ability to specify number tags in the format > `+tag=number`. It is useful for version specification of system > libraries (like libc). > > Required for the next patch. > --- > test/LuaJIT-tests/test.lua | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/test/LuaJIT-tests/test.lua b/test/LuaJIT-tests/test.lua > index ab178331..2a535605 100644 > --- a/test/LuaJIT-tests/test.lua > +++ b/test/LuaJIT-tests/test.lua > @@ -161,7 +161,12 @@ local function parse_args(t) > error(arg .." does not expect an argument") > end > elseif arg:find"^[-+]" then > - opts.tags[arg:sub(2)] = (arg:sub(1, 1) == "+") > + local tagval = arg:find"=" > + if tagval then > + opts.tags[arg:sub(2, tagval - 1)] = tonumber(arg:sub(tagval + 1)) > + else > + opts.tags[arg:sub(2)] = (arg:sub(1, 1) == "+") > + end > elseif arg:find"^%d+$" then > if not opts.numbers_to_run then > opts.numbers_to_run = {} --------------dhztB0fTDOIbJ0roZ2nxHmxe Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Hi, Sergey,

thanks for the pacth! LGTM

On 09.12.2024 13:16, Sergey Kaplun wrote:
The LuaJIT-tests suite lacks the ability to specify tags with custom
values. This patch adds the ability to specify number tags in the format
`+tag=number`. It is useful for version specification of system
libraries (like libc).

Required for the next patch.
---
 test/LuaJIT-tests/test.lua | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/test/LuaJIT-tests/test.lua b/test/LuaJIT-tests/test.lua
index ab178331..2a535605 100644
--- a/test/LuaJIT-tests/test.lua
+++ b/test/LuaJIT-tests/test.lua
@@ -161,7 +161,12 @@ local function parse_args(t)
         error(arg .." does not expect an argument")
       end
     elseif arg:find"^[-+]" then
-      opts.tags[arg:sub(2)] = (arg:sub(1, 1) == "+")
+      local tagval = arg:find"="
+      if tagval then
+        opts.tags[arg:sub(2, tagval - 1)] = tonumber(arg:sub(tagval + 1))
+      else
+        opts.tags[arg:sub(2)] = (arg:sub(1, 1) == "+")
+      end
     elseif arg:find"^%d+$" then
       if not opts.numbers_to_run then
         opts.numbers_to_run = {}
--------------dhztB0fTDOIbJ0roZ2nxHmxe--