44 lines
1.1 KiB
RPMSpec
44 lines
1.1 KiB
RPMSpec
Name: lua-lunit
|
|
Version: 0.5
|
|
Release: 15
|
|
Summary: Unit testing framework for Lua
|
|
License: MIT
|
|
URL: http://nessie.de/mroth/lunit/index.html
|
|
Source0: http://nessie.de/mroth/lunit/lunit-%{version}.tar.gz
|
|
BuildRequires: lua >= 5.2
|
|
Requires: lua >= 5.2
|
|
BuildArch: noarch
|
|
|
|
%description
|
|
Lunit is a unit testing framework for lua, written in lua.
|
|
Lunit provides 26 assert functions, and a few misc functions for usage
|
|
in an easy unit testing framework.
|
|
Lunit comes with a test suite to test itself. The testsuite consists
|
|
of approximately 710 assertions.
|
|
|
|
%prep
|
|
%autosetup -n lunit-%{version} -p1
|
|
|
|
%build
|
|
|
|
%install
|
|
install -d $RPM_BUILD_ROOT%{_bindir}
|
|
cp -p lunit $RPM_BUILD_ROOT%{_bindir}
|
|
|
|
install -d $RPM_BUILD_ROOT%{_datadir}/lua/5.2
|
|
cp -pr lunit{,-console}.lua $RPM_BUILD_ROOT%{_datadir}/lua/5.2
|
|
|
|
%check
|
|
./lunit lunit-tests.lua | tee testlog.txt
|
|
grep -q "0 failed, 0 errors" testlog.txt
|
|
|
|
%files
|
|
%doc LICENSE ANNOUNCE CHANGES DOCUMENTATION README* example.lua
|
|
%{_bindir}/lunit
|
|
%{_datadir}/lua/5.2/*
|
|
|
|
%changelog
|
|
* Mon Dec 2 2019 lijin Yang <yanglijin@huawei.com> - 0.5-15
|
|
- init package
|
|
|