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 993F26BD38; Fri, 26 Mar 2021 10:52:43 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 993F26BD38 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1616745163; bh=bcPjoExELZfqsAF7FD/N/McvlrHiFiWqC106AX8Ndno=; 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=XAFtL9gy4NrlWd50u2SixSbKBFT/wpQumB0zIUA69u9mUQCRfp2VHhhXLPkhcjYyO /pMFmNCz5KqfkXpIXIl5DLFR3umBTccoGU4cdSTUbiE2odf5yquJfvbNfO9Ayq8Hzl sTOD5DkOGjV+4h6DGmS0Au3ACkZvtNMNEfnUUvqM= Received: from smtp63.i.mail.ru (smtp63.i.mail.ru [217.69.128.43]) (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 179AD68F46 for ; Fri, 26 Mar 2021 10:44:31 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 179AD68F46 Received: by smtp63.i.mail.ru with esmtpa (envelope-from ) id 1lPh8w-00042u-7L; Fri, 26 Mar 2021 10:44:30 +0300 To: Sergey Ostanevich , Igor Munkin Date: Fri, 26 Mar 2021 10:43:00 +0300 Message-Id: <86ead4f35be1f65e9e4c0e46715d42a05851ba6d.1616743343.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: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD9064ADF4728AA0EE993662DB34D9B1ABD5A9410DDDE83AB43182A05F5380850402F04D307B548548F20EE3F035A73373704F231787ABE2834086CFC2E95A028D7 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE78CB87876C5D626D4EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F790063790B55F3E386DB9B28638F802B75D45FF914D58D5BE9E6BC131B5C99E7648C95C5DD32608FC869F5DA3A52763DD37B2426A248B5370FCDEE0A471835C12D1D9774AD6D5ED66289B5278DA827A17800CE78A0F7C24A37A3D769FA2833FD35BB23D2EF20D2F80756B5F868A13BD56FB6657A471835C12D1D977725E5C173C3A84C38D8BB953E4894305117882F4460429728AD0CFFFB425014E868A13BD56FB6657E2021AF6380DFAD1A18204E546F3947C0B7D0EA88DDEDAC722CA9DD8327EE4930A3850AC1BE2E73528A6D463EDFD0DBBC4224003CC83647689D4C264860C145E X-C1DE0DAB: C20DE7B7AB408E4181F030C43753B8186998911F362727C4C7A0BC55FA0FE5FC522CCF267CC2B9BF143E0C91E76DEA9F304C6BACCF34F872B1881A6453793CE9C32612AADDFBE061C61BE10805914D3804EBA3D8E7E5B87ABF8C51168CD8EBDB5F0C88D684269EDEDC48ACC2A39D04F89CDFB48F4795C241BDAD6C7F3747799A X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34FD9114F69CA58D1E6AA46C84E80E6DDED369593BA32F82A1C5A7B08250ED59CEA68FD0D1AA2B3C771D7E09C32AA3244C2373942A58D2797A1BCB543B97430D9624AF4FAF06DA24FD927AC6DF5659F194 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojapPp7P/VpAh8FS4b4IfFVw== X-Mailru-Sender: 3B9A0136629DC91206CBC582EFEF4CB42F3F846EB5B0E44CC37CE200D0FCECB732CACEAB7AB8D159F2400F607609286E924004A7DEC283833C7120B22964430C52B393F8C72A41A89437F6177E88F7363CDA0F3B3F5B9367 X-Mras: Ok Subject: [Tarantool-patches] [PATCH v2 luajit 17/30] test: disable locale-depended tests for Lua suite 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()` depended on the locale for parsing, unlike Lua does. See for more info. Locale-depended tests in are disabled. Part of tarantool/tarantool#5845 Part of tarantool/tarantool#4473 --- test/PUC-Lua-5.1-tests/literals.lua | 5 +++++ test/PUC-Lua-5.1-tests/strings.lua | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/test/PUC-Lua-5.1-tests/literals.lua b/test/PUC-Lua-5.1-tests/literals.lua index 01d84d5..1b4f664 100644 --- a/test/PUC-Lua-5.1-tests/literals.lua +++ b/test/PUC-Lua-5.1-tests/literals.lua @@ -158,6 +158,10 @@ end -- testing decimal point locale +-- LuaJIT: LuaJIT doesn't use `strtod()` depended 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-Lua-5.1-tests/strings.lua b/test/PUC-Lua-5.1-tests/strings.lua index 7c1dfb8..6ae3f51 100644 --- a/test/PUC-Lua-5.1-tests/strings.lua +++ b/test/PUC-Lua-5.1-tests/strings.lua @@ -162,6 +162,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 @@ -176,6 +180,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