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 40CBA27D585; Thu, 19 Jan 2023 19:26:56 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 40CBA27D585 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1674145616; bh=Y4thRveN9wOeA24bmCzV9BJEWKFUOunJge0KtqTOg+4=; h=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=gObkC14FEuJ542mXN982B0KbmA+2DYsusRLfCI+DxB/IEMXmIcltYOEK0e0wzpXp6 DysOZx9M70JXPa5Vif+whk0ch2kQWXSEihlasVsUOwktJdJzR4bSHMG1mWk0jDdfNQ RWTW4b2PX5ufvj5alWVXF98B3ZF3YC54QdwM3w8U= Received: from smtp40.i.mail.ru (smtp40.i.mail.ru [95.163.41.81]) (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 34A1B27D585 for ; Thu, 19 Jan 2023 19:26:54 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 34A1B27D585 Received: by smtp40.i.mail.ru with esmtpa (envelope-from ) id 1pIXkb-001VNw-8R; Thu, 19 Jan 2023 19:26:53 +0300 To: Sergey Ostanevich , Maxim Kokryashkin Date: Thu, 19 Jan 2023 19:23:29 +0300 Message-Id: <20230119162329.31893-1-skaplun@tarantool.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Mailru-Src: smtp X-7564579A: 78E4E2B564C1792B X-77F55803: 4F1203BC0FB41BD94A31EA4B0797EF2E80AAD164826E3087E8258EBC6D1EDC74182A05F53808504027FA45AE8F940F3AE83FA0E57E56C98DA0C765D600C3CC633CA043B4B688A407 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE79FF7180C05A1FF7CEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637657EF45424029EDA8638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D84F5FDCABA9DAA43F7AB9667756407C1B117882F4460429724CE54428C33FAD305F5C1EE8F4F765FCF1175FABE1C0F9B6A471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F4460429728776938767073520C65AC60A1F0286FEC26CFBAC0749D213D2E47CDBA5A96583BA9C0B312567BB2376E601842F6C81A19E625A9149C048EEC24E1E72F37C03A028F6BDBBAB179F4ED8FC6C240DEA7642DBF02ECDB25306B2B78CF848AE20165D0A6AB1C7CE11FEE3034D30FDF2F620DB9735652A29929C6CC4224003CC836476E2F48590F00D11D6E2021AF6380DFAD1A18204E546F3947CB11811A4A51E3B096D1867E19FE1407959CC434672EE6371089D37D7C0E48F6C8AA50765F7900637BBEA499411984DA1EFF80C71ABB335746BA297DBC24807EABDAD6C7F3747799A X-C1DE0DAB: 0D63561A33F958A50590D1D9F00B2748EA52ABA61ECD736421EC25DA3212EA434EAF44D9B582CE87C8A4C02DF684249CC203C45FEA855C8F X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D346B71C4B0698719D7FB5BF0B4D9521762A8848D043D1B36164EE99FAB2F8E07E97730CEACD38128A81D7E09C32AA3244CF084FD91455C3C6CE267A81F504341ECA95CA90A1D8AC565927AC6DF5659F194 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojqkNrV40V0b7PtqSBp6TzHQ== X-Mailru-Sender: F16D9CAFEEA6770E7B6EAD4ADB3BCAF0A704A0FF2E59D41B4DAA79FA6B128743694B185C73C1899BF2400F607609286E924004A7DEC283833C7120B22964430C52B393F8C72A41A84198E0F3ECE9B5443453F38A29522196 X-Mras: Ok Subject: [Tarantool-patches] [PATCH luajit] test: add test for `string.char('%c', 0)` 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" This patch adds the test for the commit 430d9f8f7ebb779948dbd43944b876b1a3f58551 ("Fix string.format("%c", 0)."). Although, the issue affects 2.0 branch only, there is no need to fix it. Nevertheless, the test is required to avoid regressions in the future. Part of tarantool/tarantool#8069 --- PR: https://github.com/tarantool/tarantool/pull/8189 Branch: https://github.com/tarantool/luajit/tree/skaplun/lj-378-string-format-c-null-char-full-ci Issues: * https://github.com/tarantool/tarantool/issues/8069 * https://github.com/LuaJIT/LuaJIT/issues/378 .../lj-378-string-format-c-null-char.test.lua | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 test/tarantool-tests/lj-378-string-format-c-null-char.test.lua diff --git a/test/tarantool-tests/lj-378-string-format-c-null-char.test.lua b/test/tarantool-tests/lj-378-string-format-c-null-char.test.lua new file mode 100644 index 00000000..15cefadf --- /dev/null +++ b/test/tarantool-tests/lj-378-string-format-c-null-char.test.lua @@ -0,0 +1,11 @@ +local tap = require('tap') + +local test = tap.test('lj-378-string-format-c-null-char') +test:plan(1) + +-- Test file to check that there is no regression in +-- `string.format('%c', 0)` behaviour. +-- See also https://github.com/LuaJIT/LuaJIT/issues/378. + +test:is(string.format('%c', 0), '\0', 'string.format %c on null char') +os.exit(test:check() and 0 or 1) -- 2.34.1