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 E0FAF6EC5C; Sat, 30 Jan 2021 01:39:19 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org E0FAF6EC5C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1611959960; bh=fDTv1+wgDe+N6MY5b+J6IdkG5bEKd5aIZn2ydDWRGX8=; h=To:References:Date:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=Rk5EJHXg6/A0HQToUaF/7UCdOPNnaK1LFJ/M6skcAiR+JdcFWGBdUydW/5BnApAsR Ih1auR+SvncIgZRnIPR7cqXVEWwSfvXl9kRRPaXE/UiPUFUgf7Ocwxz+v7muuXxx1e U5CVBF5AaL7VXOISA900p6VXH6Z07OG+uHy085so= Received: from smtp34.i.mail.ru (smtp34.i.mail.ru [94.100.177.94]) (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 CBFFF6EC5C for ; Sat, 30 Jan 2021 01:39:18 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org CBFFF6EC5C Received: by smtp34.i.mail.ru with esmtpa (envelope-from ) id 1l5cQ9-0007bY-TK; Sat, 30 Jan 2021 01:39:18 +0300 To: Vladislav Shpilevoy , tarantool-patches@dev.tarantool.org References: <2784ee79c0a4cdf900bc49821d50f44c9317d7e5.1611232655.git.sergeyb@tarantool.org> <3283e4df-e15b-f8b8-f2f4-a93b26bc427b@tarantool.org> Message-ID: <17837247-c677-1957-6ecd-93b305b08a35@tarantool.org> Date: Sat, 30 Jan 2021 01:39:17 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <3283e4df-e15b-f8b8-f2f4-a93b26bc427b@tarantool.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD953AC099BC0052A9C4647521586BE7E637AB8B70F7375365A182A05F538085040431430E5810A4A003F01101F9A08DB979AA5D70566E94A9BAF6A7A5B7669B353 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7ABF4E7777AC3C096EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637E0942BECCAD85D078638F802B75D45FF5571747095F342E8C7A0BC55FA0FE5FCFCDA848A502F55F5C96821DAE3DC5DDD1F9BF22A4E2D8BD8389733CBF5DBD5E913377AFFFEAFD269176DF2183F8FC7C0D9442B0B5983000E8941B15DA834481FCF19DD082D7633A0EF3E4896CB9E6436389733CBF5DBD5E9D5E8D9A59859A8B652D31B9D28593E51CC7F00164DA146DA6F5DAA56C3B73B237318B6A418E8EAB8D32BA5DBAC0009BE9E8FC8737B5C22491123BDE8DC48DA3876E601842F6C81A12EF20D2F80756B5F7E9C4E3C761E06A776E601842F6C81A127C277FBC8AE2E8B751900AEC86DACBC3AA81AA40904B5D9DBF02ECDB25306B2B25CBF701D1BE8734AD6D5ED66289B5278DA827A17800CE71878E14E9E51860367F23339F89546C5A8DF7F3B2552694A6FED454B719173D6725E5C173C3A84C37E190E7632119E5B35872C767BF85DA2F004C906525384306FED454B719173D6462275124DF8B9C9DE2850DD75B2526BE5BFE6E7EFDEDCD789D4C264860C145E X-C1DE0DAB: 0D63561A33F958A52517AF6E0F477784720CB774AA80DB9F111A1B9AE2F8D595D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA75448CF9D3A7B2C848410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D342B8615F5CFAD9D02F91096DFDB55A3E928C19033DB267FB4DDE94A4BA3BEC9903C0EC0034AB7BC171D7E09C32AA3244CAA438AAA8940F28A2EF67387E16B5A7F55E75C8D0ED9F6EEFACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2bioj0axADxPFAF9BRe8h8HDNig== X-Mailru-Sender: C4F68CFF4024C8867DFDF7C7F258845844518A3C844F9D1A453073D54D686599DD40DC63F2C6AA45282EC151BADDC1D3523A6D01B4765B2DFB59E2DDD9FE06B14FA522850F29BC30112434F685709FCF0DA7A0AF5A3A8387 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v8 07/14] test: fix luacheck warnings W231 in test/sql-tap 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" Thanks for review! On 24.01.2021 20:35, Vladislav Shpilevoy wrote: > Thanks for the patch! > > On 21.01.2021 13:50, sergeyb@tarantool.org wrote: >> From: Sergey Bronnikov >> >> W231 (Local variable is set but never accessed) >> >> Part of #5464 >> --- >> diff --git a/test/sql-tap/e_expr.test.lua b/test/sql-tap/e_expr.test.lua >> index 5f8b206d3..b488bdc60 100755 >> --- a/test/sql-tap/e_expr.test.lua >> +++ b/test/sql-tap/e_expr.test.lua >> @@ -2554,9 +2550,6 @@ test:do_test( >> -- evaluation of the THEN expression that corresponds to the first WHEN >> -- expression that evaluates to true. >> -- >> -a = 0 >> -b = 1 >> -c = 0 > These look like an artifact of a wrong conversion from TCL to Lua. > The variables are used in the SQL statements. I think the converter > thought it could just declare them as Lua variables to make visible > in SQL. Better keep them and add MUST_WORK_TEST if it is not here yet. Reverted changes with removing variables and added luacheck inline suppression: --- a/.luacheckrc +++ b/.luacheckrc @@ -51,8 +51,6 @@ exclude_files = {  files["test/sql-tap/**/*.lua"] = {      ignore = { -        -- Local variable is set but never accessed. -        "231",          -- "Value assigned to a local variable is unused."          "311",          -- Unreachable code. diff --git a/test/sql-tap/e_expr.test.lua b/test/sql-tap/e_expr.test.lua index 5f8b206d3..5ecd7b7ae 100755 --- a/test/sql-tap/e_expr.test.lua +++ b/test/sql-tap/e_expr.test.lua @@ -2486,7 +2486,7 @@ test:do_execsql_test(          --      }) -local a, b, c +local a, b, c -- luacheck: ignore unused a b c  a = 0  b = 0  c = 0 What does comment with MUST_WORK_TEST mean? > So in future we would see the expected variable values, and either > decide fix the tests or delete them entirely. The latter can easily > happen due to how much the type system was reworked. > >> test:do_execsql_test( >> "e_expr-21.2.1", >> [[