diff options
author | nia <nia@pkgsrc.org> | 2020-07-10 10:26:59 +0000 |
---|---|---|
committer | nia <nia@pkgsrc.org> | 2020-07-10 10:26:59 +0000 |
commit | 78a0580b236665611ab8c41a76df948ea97ded94 (patch) | |
tree | 90daa5285fca6393f775f1923e219a5ed8df0670 /devel | |
parent | 8b2a1054ea733b2ca6d18aa15b817d03031932c8 (diff) | |
download | pkgsrc-78a0580b236665611ab8c41a76df948ea97ded94.tar.gz |
devel: Add lua-cov
LuaCov is a simple coverage analyzer for Lua scripts. When a Lua script is
run with the luacov module loaded, it generates a stats file with the number
of executions of each line of the script and its loaded modules. The luacov
command-line script then processes this file generating a report file which
allows one to visualize which code paths were not traversed, which is useful
for verifying the effectiveness of a test suite.
Diffstat (limited to 'devel')
-rw-r--r-- | devel/Makefile | 3 | ||||
-rw-r--r-- | devel/lua-cov/DESCR | 6 | ||||
-rw-r--r-- | devel/lua-cov/Makefile | 45 | ||||
-rw-r--r-- | devel/lua-cov/PLIST | 26 | ||||
-rw-r--r-- | devel/lua-cov/distinfo | 6 |
5 files changed, 85 insertions, 1 deletions
diff --git a/devel/Makefile b/devel/Makefile index 90d783abd2e..077abfaec2c 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.3168 2020/07/09 13:34:02 nia Exp $ +# $NetBSD: Makefile,v 1.3169 2020/07/10 10:26:59 nia Exp $ # COMMENT= Development utilities @@ -855,6 +855,7 @@ SUBDIR+= lua-bitlib SUBDIR+= lua-busted SUBDIR+= lua-cliargs SUBDIR+= lua-compat53 +SUBDIR+= lua-cov SUBDIR+= lua-coxpcall SUBDIR+= lua-cqueues SUBDIR+= lua-fifo diff --git a/devel/lua-cov/DESCR b/devel/lua-cov/DESCR new file mode 100644 index 00000000000..e39a936d301 --- /dev/null +++ b/devel/lua-cov/DESCR @@ -0,0 +1,6 @@ +LuaCov is a simple coverage analyzer for Lua scripts. When a Lua script is +run with the luacov module loaded, it generates a stats file with the number +of executions of each line of the script and its loaded modules. The luacov +command-line script then processes this file generating a report file which +allows one to visualize which code paths were not traversed, which is useful +for verifying the effectiveness of a test suite. diff --git a/devel/lua-cov/Makefile b/devel/lua-cov/Makefile new file mode 100644 index 00000000000..36e0ab36bed --- /dev/null +++ b/devel/lua-cov/Makefile @@ -0,0 +1,45 @@ +# $NetBSD: Makefile,v 1.1 2020/07/10 10:26:59 nia Exp $ + +DISTNAME= luacov-0.14.0 +PKGNAME= ${LUA_PKGPREFIX}-${DISTNAME:S/^lua//1} +CATEGORIES= lua devel +MASTER_SITES= ${MASTER_SITE_GITHUB:=keplerproject/} +GITHUB_PROJECT= luacov +GITHUB_TAG= v${PKGVERSION_NOREV} + +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= https://keplerproject.github.io/luacov/ +COMMENT= Simple coverage analyzer for Lua scripts +LICENSE= mit + +NO_BUILD= yes +USE_LANGUAGES= # none + +PLIST_SUBST+= LUADOTVER=${_LUA_DOT_VERSION} + +REPLACE_LUA+= src/bin/luacov + +INSTALLATION_DIRS+= bin +INSTALLATION_DIRS+= ${LUA_LDIR}/luacov +INSTALLATION_DIRS+= ${LUA_LDIR}/luacov/reporter +INSTALLATION_DIRS+= ${LUA_DOCDIR}/doc/modules + +do-install: + ${INSTALL_SCRIPT} ${WRKSRC}/src/bin/luacov \ + ${DESTDIR}${PREFIX}/bin/luacov${_LUA_DOT_VERSION} + ${INSTALL_DATA} ${WRKSRC}/src/luacov.lua \ + ${DESTDIR}${PREFIX}/${LUA_LDIR} + ${INSTALL_DATA} ${WRKSRC}/src/luacov/*.lua \ + ${DESTDIR}${PREFIX}/${LUA_LDIR}/luacov + ${INSTALL_DATA} ${WRKSRC}/src/luacov/reporter/*.lua \ + ${DESTDIR}${PREFIX}/${LUA_LDIR}/luacov/reporter + cd ${WRKSRC}/doc && ${INSTALL_DATA} *.html *.css *.png \ + ${DESTDIR}${PREFIX}/${LUA_DOCDIR} + cd ${WRKSRC}/doc/doc && ${INSTALL_DATA} *.html *.css \ + ${DESTDIR}${PREFIX}/${LUA_DOCDIR}/doc + cd ${WRKSRC}/doc/doc/modules && ${INSTALL_DATA} *.html \ + ${DESTDIR}${PREFIX}/${LUA_DOCDIR}/doc/modules + +.include "../../lang/lua/application.mk" +.include "../../lang/lua/module.mk" +.include "../../mk/bsd.pkg.mk" diff --git a/devel/lua-cov/PLIST b/devel/lua-cov/PLIST new file mode 100644 index 00000000000..d732f38b402 --- /dev/null +++ b/devel/lua-cov/PLIST @@ -0,0 +1,26 @@ +@comment $NetBSD: PLIST,v 1.1 2020/07/10 10:26:59 nia Exp $ +bin/luacov${LUADOTVER} +${LUA_DOCDIR}/doc.css +${LUA_DOCDIR}/doc/index.html +${LUA_DOCDIR}/doc/ldoc.css +${LUA_DOCDIR}/doc/modules/luacov.defaults.html +${LUA_DOCDIR}/doc/modules/luacov.hook.html +${LUA_DOCDIR}/doc/modules/luacov.html +${LUA_DOCDIR}/doc/modules/luacov.reporter.html +${LUA_DOCDIR}/doc/modules/luacov.runner.html +${LUA_DOCDIR}/doc/modules/luacov.stats.html +${LUA_DOCDIR}/doc/modules/luacov.tick.html +${LUA_DOCDIR}/doc/modules/luacov.util.html +${LUA_DOCDIR}/index.html +${LUA_DOCDIR}/license.html +${LUA_DOCDIR}/luacov.png +${LUA_LDIR}/luacov.lua +${LUA_LDIR}/luacov/defaults.lua +${LUA_LDIR}/luacov/hook.lua +${LUA_LDIR}/luacov/linescanner.lua +${LUA_LDIR}/luacov/reporter.lua +${LUA_LDIR}/luacov/reporter/default.lua +${LUA_LDIR}/luacov/runner.lua +${LUA_LDIR}/luacov/stats.lua +${LUA_LDIR}/luacov/tick.lua +${LUA_LDIR}/luacov/util.lua diff --git a/devel/lua-cov/distinfo b/devel/lua-cov/distinfo new file mode 100644 index 00000000000..e629dd68814 --- /dev/null +++ b/devel/lua-cov/distinfo @@ -0,0 +1,6 @@ +$NetBSD: distinfo,v 1.1 2020/07/10 10:26:59 nia Exp $ + +SHA1 (luacov-0.14.0.tar.gz) = d10c25af154b6d6b19197fcccdc48fa5362ea1a5 +RMD160 (luacov-0.14.0.tar.gz) = eab58848f391fb78202816f2897ba2c7a801ef62 +SHA512 (luacov-0.14.0.tar.gz) = 44ea158ce597f705d80b9768676e401804daea91b9c2afb146a8d25aae612e895e4f42a29c4b7b3438659c596fa500af5d23b66b7f3477459747ad06ca9b7ffa +Size (luacov-0.14.0.tar.gz) = 49571 bytes |