diff --git a/README.md b/README.md index d825c00..5ee5e65 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # nunit +Unit test framework for CLI. + diff --git a/nunit.pc b/nunit.pc new file mode 100644 index 0000000..ff1f497 --- /dev/null +++ b/nunit.pc @@ -0,0 +1,8 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=${exec_prefix}/lib + +Name: NUnit +Description: Testing framework for CLI +Version: 3.6.0.0 +Libs: -r:${libdir}/mono/nunit/nunit.framework.dll -r:${libdir}/mono/nunit/nunit.framework.tests.dll -r:${libdir}/mono/nunit/nunit.testdata.dll -r:${libdir}/mono/nunit/nunitlite.dll diff --git a/nunit.spec b/nunit.spec new file mode 100644 index 0000000..ff70d4c --- /dev/null +++ b/nunit.spec @@ -0,0 +1,87 @@ +Name: nunit +Version: 3.7.1 +Release: 1mamba +Summary: Unit test framework for CLI +Group: Applications/Development +Vendor: openmamba +Distribution: openmamba +Packager: Silvan Calarco +URL: https://nunit.org/ +Source: https://github.com/nunit/nunit.git/%{version}/nunit-%{version}.tar.bz2 +Source1: nunit.pc +Source2: nunitlite-runner.sh +License: MIT +## AUTOBUILDREQ-BEGIN +## AUTOBUILDREQ-END +BuildRequires: mono-devel +Provides: mono-nunit +Obsoletes: mono-nunit < 6.12.0.122 + +%description +Unit test framework for CLI. + +%package devel +Group: Development/Libraries +Summary: Development files for %{name} +Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release} +Requires: pkg-config + +%description devel +This package contains libraries and header files for developing applications that use %{name}. + +#% debug_package + +%prep +%setup -q + +%build +# Remove prebuilt binaries +find . -name "*.dll" -print -delete + +xbuild /property:Configuration=Release src/NUnitFramework/framework/nunit.framework-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/nunitlite/nunitlite-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/nunitlite-runner/nunitlite-runner-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/mock-assembly/mock-assembly-4.5.csproj + +xbuild /property:Configuration=Release src/NUnitFramework/slow-tests/slow-nunit-tests-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/testdata/nunit.testdata-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/tests/nunit.framework.tests-4.5.csproj +xbuild /property:Configuration=Release src/NUnitFramework/nunitlite.tests/nunitlite.tests-4.5.csproj + +%install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" +install -d -m0755 %{buildroot}{%{_prefix}/lib/mono/nunit,%{_libdir}/pkgconfig,%{_bindir},%{_datadir}/applications,%{_datadir}/icons/NUnit} + +%{__install} -m0644 %{SOURCE1} %{buildroot}%{_libdir}/pkgconfig/ +%{__install} -m0755 %{SOURCE2} %{buildroot}%{_bindir}/nunitlite-runner + +%{__install} -m0644 src/NUnitFramework/nunitlite-runner/App.config %{buildroot}%{_prefix}/lib/mono/nunit/nunitlite-runner.exe.config +find %{_builddir}/%{?buildsubdir}/bin -name \*.dll -exec %{__install} \-m0755 "{}" "%{buildroot}%{_prefix}/lib/mono/nunit/" \; +find %{_builddir}/%{?buildsubdir}/bin -name \*.exe -exec %{__install} \-m0755 "{}" "%{buildroot}%{_prefix}/lib/mono/nunit/" \; + +# FIXME? Failure adding assembly .. to the cache: Strong name cannot be verified for delay-signed assembly +#for i in nunit.framework.dll nunit.framework.tests.dll nunitlite.dll nunit.testdata.dll; do +# gacutil -i %{buildroot}%{_prefix}/lib/mono/nunit/$i -package nunit -root %{buildroot}%{_prefix}/lib/mono/../ +#done + +%clean +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +%files +%defattr(-,root,root) +%{_bindir}/nunitlite-runner +%dir %{_prefix}/lib/mono/nunit +%{_prefix}/lib/mono/nunit/* + +%files devel +%defattr(-,root,root) +%{_libdir}/pkgconfig/nunit.pc +%doc README.md + + +%changelog +* Wed Mar 08 2023 Silvan Calarco 3.7.1-1mamba +- update to 3.7.1 + +* Wed Mar 08 2023 Silvan Calarco 3.13.3-1mamba +- package created using the webbuild interface diff --git a/nunitlite-runner.sh b/nunitlite-runner.sh new file mode 100644 index 0000000..740e964 --- /dev/null +++ b/nunitlite-runner.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /usr/bin/mono /usr/lib/mono/nunit/nunitlite-runner.exe "$@"