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 8A96B6EC5F; Tue, 13 Apr 2021 23:31:33 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 8A96B6EC5F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1618345893; bh=ZFmAvJzPc/yXJSOJ0hFxt7bVma2cYbhbx2YjcM8vCFs=; h=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=kPxuE6i8XrMSq1yC7JFLwlLmJnBUGNzcL62kgIsYqs8Ej1HTatX6SL4c+K4KdijNN O5ulzluuDayLNMakW1fRdVUB9Bs5TQnKD+64jSYNELI5MFiVs75dincDxvV9kGYO6T VUE2UmfOwKp/h48mVO3YIgJgv29VaPa3ABGVelaw= Received: from smtpng1.m.smailru.net (smtpng1.m.smailru.net [94.100.181.251]) (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 0A3ED6EC5F for ; Tue, 13 Apr 2021 23:31:31 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 0A3ED6EC5F Received: by smtpng1.m.smailru.net with esmtpa (envelope-from ) id 1lWPh4-00086G-SK; Tue, 13 Apr 2021 23:31:31 +0300 Date: Tue, 13 Apr 2021 23:31:18 +0300 To: Sergey Kaplun Message-ID: <20210413203118.GX29703@tarantool.org> References: <9f2ac107a3dce0b4a48ecde1aa95ec1f99800916.1618320000.git.skaplun@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <9f2ac107a3dce0b4a48ecde1aa95ec1f99800916.1618320000.git.skaplun@tarantool.org> X-Clacks-Overhead: GNU Terry Pratchett User-Agent: Mutt/1.10.1 (2018-07-13) X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD92FFCB8E6708E7480BE79914FF86F9151AC38CC435EA4A654182A05F53808504010CD98DD0E5AB1E9C30AA69EF1B13EC05F790F87642D779BBAA7EE4034F2EA20 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE745229D52CF30560CEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637EFACF7FB96444C4B8638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B2CA870C4D53314BEF250BBD7DF4E1958D088CACE0DB6A842FD2E47CDBA5A96583C09775C1D3CA48CFE97D2AE7161E217F117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE7ABB305BD10C6E5099FA2833FD35BB23DF004C906525384302BEBFE083D3B9BA73A03B725D353964B0B7D0EA88DDEDAC722CA9DD8327EE4930A3850AC1BE2E7350555CCFDA08FA3FAC4224003CC83647689D4C264860C145E X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2AD77751E876CB595E8F7B195E1C97831032541D9495F9AA7BE75460A6CDB2857 X-C1DE0DAB: 0D63561A33F958A53DA55F977A46BB4814307CE49474A680DD5BEA3C0BB9E151D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA7502E6951B79FF9A3F410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D341ADA1A41A420E9B2F46342ABBD5C45780C60EA0CACF590BB24216A0505E1D30CFC78B0EFFBB0E2D91D7E09C32AA3244C2B1A264852CE0DCEB5F7601A7ECBA2CA55E75C8D0ED9F6EE927AC6DF5659F194 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojnA7/qPBUIXFOfQFbgHNd0A== X-Mailru-Sender: 689FA8AB762F73936BC43F508A0638227688FB9D0E9135B181700B4DE962C402A7C8D0F45F857DBFE9F1EFEE2F478337FB559BB5D741EB964C8C2C849690F8E70A04DAD6CC59E33667EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit v3 01/29] test: add PUC-Rio Lua 5.1 test 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: Igor Munkin via Tarantool-patches Reply-To: Igor Munkin Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Sergey, Thanks for the patch! LGTM with the following nits: I fixed them on top of your branch[1] and guess no re-testing is needed. On 13.04.21, Sergey Kaplun wrote: > This patch adds PUC-Rio Lua 5.1 test suite as a part of the LuaJIT test > suite. Source code is taken verbatim (except trailing whitespace) from > https://www.lua.org/tests/lua5.1-tests.tar.gz. > > Some tests may fail after this commit. They will be disabled > or adapted in the next patches. > > Part of tarantool/tarantool#5845 > Part of tarantool/tarantool#4473 > --- > diff --git a/test/PUC-Rio-Lua-5.1-tests/CMakeLists.txt b/test/PUC-Rio-Lua-5.1-tests/CMakeLists.txt > new file mode 100644 > index 00000000..e3bbc9de > --- /dev/null > +++ b/test/PUC-Rio-Lua-5.1-tests/CMakeLists.txt > @@ -0,0 +1,45 @@ > +# Test suite that has been added from PUC-Rio Lua 5.1 test archive > +# in scope of https://github.com/tarantool/tarantool/issues/5845. > + > +# See the rationale in the root CMakeLists.txt. > +cmake_minimum_required(VERSION 3.1 FATAL_ERROR) > + > +# XXX: There are two ways to set up the proper environment > +# described in the suite's README: > +# * set LUA_PATH to "?;./?.lua" > +# * or, better yet, set LUA_PATH to "./?.lua;;" and LUA_INIT to > +# "package.path = '?;'..package.path" > +# Unfortunately, Tarantool doesn't support LUA_INIT and most > +# likely it never will. For more info, see > +# https://github.com/tarantool/tarantool/issues/5744 > +# Hence, there is no way other than set LUA_PATH environment > +# variable as proposed in the first case. > +set(LUA_PATH "?\;${CMAKE_CURRENT_SOURCE_DIR}/?.lua") > + > +# Establish PUC-Lua-5.1-tests-prepare target that creates Typo: s/PUC-Lua-5.1-tests-prepare/PUC-Rio-Lua-5.1-tests-prepare/. > +# subdirectory. > +add_subdirectory(libs) > + > +# TODO: PUC-Rio Lua 5.1 test suite also has special header > +# and translation unit to check some > +# internal behaviour of the Lua implementation (see etc/ > +# directory). It modifies realloc function to check memory > +# consistency and also contains tests for yield in hooks > +# and for the Lua C API. > +# But, unfortunately, depends on specific PUC-Rio > +# Lua 5.1 internal headers and should be adapted for LuaJIT. > + > +add_custom_target(PUC-Rio-Lua-5.1-tests > + DEPENDS ${LUAJIT_TEST_BINARY} PUC-Lua-5.1-tests-prepare Typo: s/PUC-Lua-5.1-tests-prepare/PUC-Rio-Lua-5.1-tests-prepare/. > +) > + > +add_custom_command(TARGET PUC-Rio-Lua-5.1-tests > + COMMENT "Running PUC-Rio Lua 5.1 tests" > + COMMAND > + env > + LUA_PATH="${LUA_PATH}\;\;" > + ${LUAJIT_TEST_COMMAND} ${CMAKE_CURRENT_SOURCE_DIR}/all.lua > + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} > +) > + > +# vim: expandtab tabstop=2 shiftwidth=2 > diff --git a/test/PUC-Rio-Lua-5.1-tests/libs/CMakeLists.txt b/test/PUC-Rio-Lua-5.1-tests/libs/CMakeLists.txt > new file mode 100644 > index 00000000..f24e7f30 > --- /dev/null > +++ b/test/PUC-Rio-Lua-5.1-tests/libs/CMakeLists.txt > @@ -0,0 +1,18 @@ > +# Test suite that has been added from PUC-Rio Lua 5.1 test archive > +# in scope of https://github.com/tarantool/tarantool/issues/5845. > + > +# See the rationale in the root CMakeLists.txt. > +cmake_minimum_required(VERSION 3.1 FATAL_ERROR) > + > +# The original tarball contains subdirectory "libs" with an empty > +# subdirectory "libs/P1", to be used by tests. > +# Instead of tracking empty directory with some anchor-file for > +# git, create this directory via CMake. > +add_custom_target(PUC-Lua-5.1-tests-prepare) > +add_custom_command(TARGET PUC-Lua-5.1-tests-prepare Typo: s/PUC-Lua-5.1-tests-prepare/PUC-Rio-Lua-5.1-tests-prepare/g. > + COMMENT "Create directory for PUC-Rio Lua 5.1 tests" > + COMMAND ${CMAKE_COMMAND} -E make_directory P1 > + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} > +) > + > +# vim: expandtab tabstop=2 shiftwidth=2 > -- > 2.31.0 > [1]: https://github.com/tarantool/luajit/commit/47deba2 -- Best regards, IM