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 F3C346B962; Tue, 13 Apr 2021 16:37:04 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org F3C346B962 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1618321025; bh=/PsLZpVPjku2u3n0RfIvhDGo9nkJbTzEJXEZfDWgpR4=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=vw8tmDYmMgxyDEfRjNY6tfk2mmHOo6a1CyYOfiUxmY5EIW1HG5k6XC5VNzidhTFpN maOJUlNKbbbuuDK0i3LIFnq5seb82lbic6qAaSnXvjsbz8X2iYe/ZSTra4eVoH/3yS 8Oy8o+1PjnF1V2vKhUEltuPwkYv0Cg9x+ZcLjhNg= Received: from smtp48.i.mail.ru (smtp48.i.mail.ru [94.100.177.108]) (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 3CAE46B962 for ; Tue, 13 Apr 2021 16:28:51 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 3CAE46B962 Received: by smtp48.i.mail.ru with esmtpa (envelope-from ) id 1lWJ62-0000dj-CE; Tue, 13 Apr 2021 16:28:50 +0300 To: Sergey Ostanevich , Igor Munkin Date: Tue, 13 Apr 2021 16:27:17 +0300 Message-Id: <0137c1983fff3d7bf882828c0a91fe03f4dbb421.1618320000.git.skaplun@tarantool.org> X-Mailer: git-send-email 2.31.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD92FFCB8E6708E748094FADAEB10E66ADA4C48BE3C291E66DA182A05F538085040CD44B1CC2AF0A9052C79DAB8EA21BACC4F8E41D630CFE471E4C4D04F57E9070F X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7DB84ED444C624799EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006375E280A1EC162AD7D8638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B2E135279A2B46FE2B28DD1125E53C8C71EABCB1FA743BAAB4D2E47CDBA5A96583C09775C1D3CA48CF62968DCAA3E4B45B117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE71DD432BB81541BCF9FA2833FD35BB23DF004C906525384302BEBFE083D3B9BA73A03B725D353964B0B7D0EA88DDEDAC722CA9DD8327EE4933F735096452955E3BA6625F88748EAEFC4224003CC83647689D4C264860C145E X-C1DE0DAB: C20DE7B7AB408E4181F030C43753B8186998911F362727C4C7A0BC55FA0FE5FC7F657775A4D63968FABDF8FC640C8198725194BF57538EB2B1881A6453793CE9C32612AADDFBE061C61BE10805914D3804EBA3D8E7E5B87ABF8C51168CD8EBDB63AF70AF8205D7DCDC48ACC2A39D04F89CDFB48F4795C241BDAD6C7F3747799A X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34411AA3F52B5778B6E7CDE2D20446120A802A113181716BE2AEF08D963A3CE5B68E85022846C52AE11D7E09C32AA3244CA090752BA17D4BE7C3E4294AC0D35F10F522A1CF68F4BE05927AC6DF5659F194 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojnA7/qPBUIXFIWy6v0Z/eIQ== X-Mailru-Sender: 3B9A0136629DC91206CBC582EFEF4CB46F883A8D88864FC20CB0C4669B49AB2CD45F19E64A1574ABF2400F607609286E924004A7DEC283833C7120B22964430C52B393F8C72A41A89437F6177E88F7363CDA0F3B3F5B9367 X-Mras: Ok Subject: [Tarantool-patches] [PATCH luajit v3 17/29] test: disable locale-dependent PUC-Rio 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 Kaplun via Tarantool-patches Reply-To: Sergey Kaplun Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" LuaJIT doesn't compare strings by `strcoll()`, like Lua 5.1 does. So locale-depended tests in are disabled. Also, LuaJIT doesn't use `strtod()` dependent on the locale for parsing, unlike Lua does. See for more info. See also http://luajit.org/extensions.html#tonumber. Locale-depended tests in are disabled. Part of tarantool/tarantool#5845 Part of tarantool/tarantool#4473 --- test/PUC-Rio-Lua-5.1-tests/literals.lua | 5 +++++ test/PUC-Rio-Lua-5.1-tests/strings.lua | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/test/PUC-Rio-Lua-5.1-tests/literals.lua b/test/PUC-Rio-Lua-5.1-tests/literals.lua index 01d84d5a..4fc3e88d 100644 --- a/test/PUC-Rio-Lua-5.1-tests/literals.lua +++ b/test/PUC-Rio-Lua-5.1-tests/literals.lua @@ -158,6 +158,10 @@ end -- testing decimal point locale +-- LuaJIT: LuaJIT doesn't use `strtod()` dependent on the locale, +-- unlike Lua does. See for more info. +-- Tests are disabled for LuaJIT. +--[[ if os.setlocale("pt_BR") or os.setlocale("ptb") then assert(tonumber("3,4") == 3.4 and tonumber"3.4" == nil) assert(assert(loadstring("return 3.4"))() == 3.4) @@ -171,6 +175,7 @@ else (Message or print)( '\a\n >>> pt_BR locale not available: skipping decimal point tests <<<\n\a') end +--]] print('OK') diff --git a/test/PUC-Rio-Lua-5.1-tests/strings.lua b/test/PUC-Rio-Lua-5.1-tests/strings.lua index 0eee4c6e..67e42cb6 100644 --- a/test/PUC-Rio-Lua-5.1-tests/strings.lua +++ b/test/PUC-Rio-Lua-5.1-tests/strings.lua @@ -188,6 +188,10 @@ local function trylocale (w) return false end +-- LuaJIT: LuaJIT doesn't compare strings by `strcoll()`, +-- like Lua 5.1 does. +-- Tests are disabled for LuaJIT. +--[[ if not trylocale("collate") then print("locale not supported") else @@ -202,6 +206,7 @@ else assert(string.gsub("áÁéÉ", "%u", "x") == "áxéx") assert(string.upper"áÁé{xuxu}ção" == "ÁÁÉ{XUXU}ÇÃO") end +--]] os.setlocale("C") assert(os.setlocale() == 'C') -- 2.31.0