From 4160186131fc18a6497c98762341eb3ab6ec88f5 Mon Sep 17 00:00:00 2001 From: Conrad Kostecki Date: Wed, 14 Oct 2020 23:08:49 +0200 Subject: dev-lua/luadbi: add tests Uunfortunately, the tests must be restricted, as they need a real database for execution. Package-Manager: Portage-3.0.8, Repoman-3.0.1 Signed-off-by: Conrad Kostecki --- dev-lua/luadbi/luadbi-0.7.2.ebuild | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'dev-lua') diff --git a/dev-lua/luadbi/luadbi-0.7.2.ebuild b/dev-lua/luadbi/luadbi-0.7.2.ebuild index 63e97642ea17..3c01ee07123f 100644 --- a/dev-lua/luadbi/luadbi-0.7.2.ebuild +++ b/dev-lua/luadbi/luadbi-0.7.2.ebuild @@ -12,8 +12,9 @@ SRC_URI="https://github.com/mwild1/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" LICENSE="MIT" SLOT="0" KEYWORDS="~amd64 ~arm ~arm64 ~x86" -IUSE="mysql postgres +sqlite" +IUSE="mysql postgres +sqlite test" REQUIRED_USE="|| ( mysql postgres sqlite )" +RESTRICT="test" RDEPEND=" >=dev-lang/lua-5.1:= @@ -47,6 +48,10 @@ src_compile() { use sqlite emake ${myemakeargs} SQLITE3_INC="-I/usr/include" sqlite } +src_test() { + cd "${S}"/tests && lua run_tests.lua || die +} + src_install() { local myemakeargs=( DESTDIR="${ED}" -- cgit v1.2.3-65-gdbad