|
|
3d1480 |
Name: cmocka
|
|
|
3a4493 |
Version: 1.1.5
|
|
|
3d1480 |
Release: 1%{?dist}
|
|
|
3d1480 |
|
|
|
3d1480 |
License: ASL 2.0
|
|
|
3d1480 |
Summary: An elegant unit testing framework for C with support for mock objects
|
|
|
3d1480 |
URL: https://cmocka.org
|
|
|
3d1480 |
|
|
|
3d1480 |
Source0: https://cmocka.org/files/1.1/%{name}-%{version}.tar.xz
|
|
|
3d1480 |
Source1: https://cmocka.org/files/1.1/%{name}-%{version}.tar.xz.asc
|
|
|
3d1480 |
Source2: cmocka.keyring
|
|
|
3d1480 |
|
|
|
3d1480 |
BuildRequires: gcc
|
|
|
3d1480 |
BuildRequires: cmake
|
|
|
3d1480 |
BuildRequires: doxygen
|
|
|
3d1480 |
BuildRequires: glibc-devel
|
|
|
3d1480 |
BuildRequires: gnupg2
|
|
|
3d1480 |
|
|
|
3d1480 |
%description
|
|
|
3d1480 |
There are a variety of C unit testing frameworks available however many of them
|
|
|
3d1480 |
are fairly complex and require the latest compiler technology. Some development
|
|
|
3d1480 |
requires the use of old compilers which makes it difficult to use some unit
|
|
|
3d1480 |
testing frameworks. In addition many unit testing frameworks assume the code
|
|
|
3d1480 |
being tested is an application or module that is targeted to the same platform
|
|
|
3d1480 |
that will ultimately execute the test. Because of this assumption many
|
|
|
3d1480 |
frameworks require the inclusion of standard C library headers in the code
|
|
|
3d1480 |
module being tested which may collide with the custom or incomplete
|
|
|
3d1480 |
implementation of the C library utilized by the code under test.
|
|
|
3d1480 |
|
|
|
3d1480 |
Cmocka only requires a test application is linked with the standard C library
|
|
|
3d1480 |
which minimizes conflicts with standard C library headers. Also, CMocka tries
|
|
|
3d1480 |
to avoid the use of some of the newer features of C compilers.
|
|
|
3d1480 |
|
|
|
3d1480 |
This results in CMocka being a relatively small library that can be used to
|
|
|
3d1480 |
test a variety of exotic code. If a developer wishes to simply test an
|
|
|
3d1480 |
application with the latest compiler then other unit testing frameworks may be
|
|
|
3d1480 |
preferable.
|
|
|
3d1480 |
|
|
|
3d1480 |
This is the successor of Google's Cmockery.
|
|
|
3d1480 |
|
|
|
3d1480 |
%package -n libcmocka
|
|
|
3d1480 |
Summary: Lightweight library to simplify and generalize unit tests for C
|
|
|
3d1480 |
|
|
|
3d1480 |
Conflicts: cmockery2
|
|
|
3d1480 |
|
|
|
3d1480 |
%description -n libcmocka
|
|
|
3d1480 |
There are a variety of C unit testing frameworks available however many of them
|
|
|
3d1480 |
are fairly complex and require the latest compiler technology. Some development
|
|
|
3d1480 |
requires the use of old compilers which makes it difficult to use some unit
|
|
|
3d1480 |
testing frameworks. In addition many unit testing frameworks assume the code
|
|
|
3d1480 |
being tested is an application or module that is targeted to the same platform
|
|
|
3d1480 |
that will ultimately execute the test. Because of this assumption many
|
|
|
3d1480 |
frameworks require the inclusion of standard C library headers in the code
|
|
|
3d1480 |
module being tested which may collide with the custom or incomplete
|
|
|
3d1480 |
implementation of the C library utilized by the code under test.
|
|
|
3d1480 |
|
|
|
3d1480 |
CMocka only requires a test application is linked with the standard C library
|
|
|
3d1480 |
which minimizes conflicts with standard C library headers. Also, CMocka tries
|
|
|
3d1480 |
to avoid the use of some of the newer features of C compilers.
|
|
|
3d1480 |
|
|
|
3d1480 |
This results in CMocka being a relatively small library that can be used to
|
|
|
3d1480 |
test a variety of exotic code. If a developer wishes to simply test an
|
|
|
3d1480 |
application with the latest compiler then other unit testing frameworks may be
|
|
|
3d1480 |
preferable.
|
|
|
3d1480 |
|
|
|
3d1480 |
This is the successor of Google's Cmockery.
|
|
|
3d1480 |
|
|
|
3d1480 |
%package -n libcmocka-static
|
|
|
3d1480 |
Summary: Lightweight library to simplify and generalize unit tests for C
|
|
|
3d1480 |
|
|
|
3d1480 |
%description -n libcmocka-static
|
|
|
3d1480 |
Static version of the cmocka library.
|
|
|
3d1480 |
|
|
|
3d1480 |
%package -n libcmocka-devel
|
|
|
3d1480 |
Summary: Development headers for the cmocka library
|
|
|
3d1480 |
Requires: libcmocka = %{version}-%{release}
|
|
|
3d1480 |
|
|
|
3d1480 |
Conflicts: cmockery2-devel
|
|
|
3d1480 |
|
|
|
3d1480 |
%description -n libcmocka-devel
|
|
|
3d1480 |
Development headers for the cmocka unit testing library.
|
|
|
3d1480 |
|
|
|
3d1480 |
%prep
|
|
|
3d1480 |
%autosetup -p1
|
|
|
3d1480 |
|
|
|
3d1480 |
%build
|
|
|
3d1480 |
if test ! -e "obj"; then
|
|
|
3d1480 |
mkdir obj
|
|
|
3d1480 |
fi
|
|
|
3d1480 |
pushd obj
|
|
|
3d1480 |
%cmake \
|
|
|
3d1480 |
-DWITH_STATIC_LIB=ON \
|
|
|
3d1480 |
-DWITH_CMOCKERY_SUPPORT=ON \
|
|
|
3d1480 |
-DUNIT_TESTING=ON \
|
|
|
3d1480 |
%{_builddir}/%{name}-%{version}
|
|
|
3d1480 |
|
|
|
3d1480 |
make %{?_smp_mflags} VERBOSE=1
|
|
|
3d1480 |
make docs
|
|
|
3d1480 |
popd
|
|
|
3d1480 |
|
|
|
3d1480 |
%install
|
|
|
3d1480 |
pushd obj
|
|
|
3d1480 |
make DESTDIR=%{buildroot} install
|
|
|
3d1480 |
popd
|
|
|
3d1480 |
ln -s libcmocka.so %{buildroot}%{_libdir}/libcmockery.so
|
|
|
3d1480 |
|
|
|
3a4493 |
%ldconfig_scriptlets -n libcmocka
|
|
|
3d1480 |
|
|
|
3d1480 |
%check
|
|
|
3d1480 |
pushd obj
|
|
|
3d1480 |
ctest --output-on-failure
|
|
|
3d1480 |
popd
|
|
|
3d1480 |
|
|
|
3d1480 |
%files -n libcmocka
|
|
|
3d1480 |
%doc AUTHORS README.md ChangeLog
|
|
|
3d1480 |
%license COPYING
|
|
|
3d1480 |
%{_libdir}/libcmocka.so.*
|
|
|
3d1480 |
|
|
|
3d1480 |
%files -n libcmocka-static
|
|
|
3a4493 |
%{_libdir}/libcmocka-static.a
|
|
|
3d1480 |
|
|
|
3d1480 |
%files -n libcmocka-devel
|
|
|
3d1480 |
%doc obj/doc/html
|
|
|
3d1480 |
%{_includedir}/cmocka.h
|
|
|
3d1480 |
%{_includedir}/cmocka_pbc.h
|
|
|
3d1480 |
%{_includedir}/cmockery/cmockery.h
|
|
|
3d1480 |
%{_includedir}/cmockery/pbc.h
|
|
|
3d1480 |
%{_libdir}/libcmocka.so
|
|
|
3d1480 |
%{_libdir}/libcmockery.so
|
|
|
3d1480 |
%{_libdir}/pkgconfig/cmocka.pc
|
|
|
3d1480 |
%{_libdir}/cmake/cmocka/cmocka-config-version.cmake
|
|
|
3d1480 |
%{_libdir}/cmake/cmocka/cmocka-config.cmake
|
|
|
3d1480 |
|
|
|
3d1480 |
%changelog
|
|
|
3a4493 |
* Thu Mar 28 2019 Andreas Schneider <asn@redhat.com> - 1.1.5-1
|
|
|
3a4493 |
- Update to version 1.1.5
|
|
|
3a4493 |
|
|
|
3a4493 |
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.3-2
|
|
|
3a4493 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
|
|
3a4493 |
|
|
|
3a4493 |
* Thu Sep 27 2018 Andreas Schneider <asn@redhat.com> - 1.1.3-1
|
|
|
3a4493 |
- Update to version 1.1.3
|
|
|
3a4493 |
|
|
|
3d1480 |
* Wed Aug 29 2018 Andreas Schneider <asn@redhat.com> - 1.1.2-1
|
|
|
3a4493 |
- Update to version 1.1.2
|
|
|
3a4493 |
|
|
|
3a4493 |
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-9
|
|
|
3a4493 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-8
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-7
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-6
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Tue Mar 28 2017 Than Ngo <than@redhat.com> - 1.1.0-5
|
|
|
3d1480 |
- added workaround for gcc7 bug on ppc64le temporary
|
|
|
3d1480 |
|
|
|
3d1480 |
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-4
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Sep 21 2016 Jakub Hrozek <jhrozek@redhat.com> - 1.1.0-1
|
|
|
3d1480 |
- Update to version 1.1.0
|
|
|
3d1480 |
* Added support to catch multiple exceptions
|
|
|
3d1480 |
* Added support to verify call ordering
|
|
|
3d1480 |
* Added support to pass initial data to test cases
|
|
|
3d1480 |
* Added will_return_maybe() for ignoring mock returns
|
|
|
3d1480 |
* Added subtests for groups using TAP output
|
|
|
3d1480 |
* Added support to write multiple XML files for groups
|
|
|
3d1480 |
* Improved documentation
|
|
|
3d1480 |
* Fixed XML output generataion
|
|
|
3d1480 |
* Fixed Windows builds with VS2015
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-3
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1-2
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Thu Mar 12 2015 Andreas Schneider <asn@redhat.com> - 1.0.1-1
|
|
|
3d1480 |
- Update to version 1.0.1:
|
|
|
3d1480 |
* Added a macro for assert_ptr_equal().
|
|
|
3d1480 |
* Fixed test_realloc() if 0 size is passed.
|
|
|
3d1480 |
* Fixed objects packaging bug.
|
|
|
3d1480 |
* Fixed building with newer gcc versions.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Mon Feb 16 2015 Andreas Schneider <asn@redhat.com> - 1.0.0-1
|
|
|
3d1480 |
- Update to version 1.0.0:
|
|
|
3d1480 |
* Added new test runner with group fixtures. The old runner is deprecated
|
|
|
3d1480 |
* Added an extensible message output formatter
|
|
|
3d1480 |
* Added jUnit XML message output
|
|
|
3d1480 |
* Added subunit message output
|
|
|
3d1480 |
* Added Test Anything Protocol message output
|
|
|
3d1480 |
* Added skip() command
|
|
|
3d1480 |
* Added test_realloc()
|
|
|
3d1480 |
* Added a cmockery compat header
|
|
|
3d1480 |
* Fixed a lot of bugs on Windows
|
|
|
3d1480 |
|
|
|
3d1480 |
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-3
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-2
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Mon May 26 2014 - Andreas Schneider <asn@redhat.com> - 0.4.1-1
|
|
|
3d1480 |
- Update to version 0.4.1.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Fri Apr 11 2014 - Andreas Schneider <asn@redhat.com> - 0.4.0-1
|
|
|
3d1480 |
- Update to version 0.4.0.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Nov 06 2013 - Andreas Schneider <asn@redhat.com> - 0.3.2-1
|
|
|
3d1480 |
- Update to version 0.3.2.
|
|
|
3d1480 |
- Include API documentation.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.1-2
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Jul 10 2013 - Andreas Schneider <asn@redhat.com> - 0.3.0-2
|
|
|
3d1480 |
- Update to version 0.3.1.
|
|
|
3d1480 |
- Fixed cmocka issues on big endian.
|
|
|
3d1480 |
- resolves: #975044
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Jun 05 2013 - Andreas Schneider <asn@redhat.com> - 0.3.0-1
|
|
|
3d1480 |
- Update to version 0.3.0.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.2.0-4
|
|
|
3d1480 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
|
|
3d1480 |
|
|
|
3d1480 |
* Fri Jan 18 2013 - Andreas Schneider <asn@redhat.com> - 0.2.0-3
|
|
|
3d1480 |
- Fixed typo in Source URL.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Thu Jan 17 2013 - Andreas Schneider <asn@redhat.com> - 0.2.0-2
|
|
|
3d1480 |
- Fixed Source URL.
|
|
|
3d1480 |
- Fixed package groups.
|
|
|
3d1480 |
|
|
|
3d1480 |
* Tue Jan 15 2013 - Andreas Schneider <asn@redhat.com> - 0.2.0-1
|
|
|
3d1480 |
- Initial version 0.2.0
|