Compare commits
5 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
64e8d6e6a6 | ||
|
|
6e7f014a6c | ||
|
|
dbc1d733ff | ||
|
|
d34f5e3085 | ||
|
|
4a1e35f624 |
12 changed files with 249 additions and 2282 deletions
|
|
@ -1 +0,0 @@
|
|||
1
|
||||
8
.gitignore
vendored
8
.gitignore
vendored
|
|
@ -60,11 +60,3 @@
|
|||
/modulemd-2.12.1.tar.xz.asc
|
||||
/modulemd-2.13.0.tar.xz
|
||||
/modulemd-2.13.0.tar.xz.asc
|
||||
/modulemd-2.14.0.tar.xz
|
||||
/modulemd-2.14.0.tar.xz.asc
|
||||
/modulemd-2.15.0.tar.xz
|
||||
/modulemd-2.15.0.tar.xz.asc
|
||||
/modulemd-2.15.1.tar.xz
|
||||
/modulemd-2.15.1.tar.xz.asc
|
||||
/modulemd-2.15.2.tar.xz
|
||||
/modulemd-2.15.2.tar.xz.asc
|
||||
|
|
|
|||
|
|
@ -2,11 +2,10 @@ specfile_path: libmodulemd.spec
|
|||
upstream_package_name: libmodulemd
|
||||
downstream_package_name: libmodulemd
|
||||
upstream_tag_template: libmodulemd-{version}
|
||||
current_version_command:
|
||||
- ./.packit_version.sh
|
||||
|
||||
actions:
|
||||
get-current-version: ./.packit_version.sh
|
||||
|
||||
files_to_sync:
|
||||
synced_files:
|
||||
- .packit.yml
|
||||
- .make_packit_specfile.sh
|
||||
- libmodulemd.spec
|
||||
|
|
|
|||
|
|
@ -1,16 +1,15 @@
|
|||
--- !Policy
|
||||
product_versions:
|
||||
- fedora-rawhide
|
||||
decision_context: bodhi_update_push_stable
|
||||
- fedora-*
|
||||
decision_context: bodhi_update_push_testing
|
||||
subject_type: koji_build
|
||||
rules:
|
||||
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpmdeplint.functional}
|
||||
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
|
||||
|
||||
--- !Policy
|
||||
product_versions:
|
||||
- fedora-*
|
||||
decision_context: bodhi_update_push_stable
|
||||
subject_type: koji_build
|
||||
rules:
|
||||
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.installability.functional}
|
||||
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpminspect.static-analysis}
|
||||
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
|
||||
|
|
|
|||
128
libmodulemd.spec
128
libmodulemd.spec
|
|
@ -23,26 +23,24 @@
|
|||
%endif
|
||||
|
||||
Name: %{upstream_name}%{?v2_suffix}
|
||||
Version: 2.15.2
|
||||
Release: 5%{?dist}
|
||||
Version: 2.13.0
|
||||
Release: 2%{?dist}
|
||||
Summary: Module metadata manipulation library
|
||||
|
||||
# COPYING: MIT
|
||||
## not in any binary package
|
||||
# contrib/coverity-modeling.c: GPL-2.0-or-later
|
||||
# contrib/release-tools/semver: GPL-3.0-only
|
||||
# modulemd/tests/test_data/f29.yaml: Apache-2.0
|
||||
# modulemd/tests/test_data/f29-updates.yaml: Apache-2.0
|
||||
# xml_specs/reduced/tests/good/module_stream_build_license.xml: MIT AND GPL-3.0-or-later
|
||||
# contrib/coverity-modeling.c: GPLv2+
|
||||
# contrib/release-tools/semver: GPLv3
|
||||
License: MIT
|
||||
SourceLicense: %{license} AND GPL-3.0-only AND GPL-3.0-or-later AND GPL-2.0-or-later AND Apache-2.0
|
||||
URL: https://github.com/fedora-modularity/libmodulemd
|
||||
Source0: %{url}/releases/download/%{version}/modulemd-%{version}.tar.xz
|
||||
Source1: %{url}/releases/download/%{version}/modulemd-%{version}.tar.xz.asc
|
||||
# Key exported from Petr Pisar's keyring
|
||||
Source2: gpgkey-E3F42FCE156830A80358E6E94FD1AEC3365AF7BF.gpg
|
||||
# Adapt tests to glib2-2.87.0, in upstream after 2.15.2, bug #2423153
|
||||
Patch0: modulemd-2.15.2-tests-Adapt-to-glib-2.87.0.patch
|
||||
# Accept invalid, but existing buildorder 18446744073709551615 when loading
|
||||
# modulemd-v2 documents, bug #1984402, <https://pagure.io/koji/issue/3025>,
|
||||
# in upstream after 2.13.0
|
||||
Patch0: modulemd-2.13.0-Accept-18446744073709551615-buildorder-if-accept_ove.patch
|
||||
|
||||
BuildRequires: gnupg2
|
||||
BuildRequires: meson >= 0.47
|
||||
|
|
@ -55,6 +53,7 @@ BuildRequires: pkgconfig(yaml-0.1)
|
|||
BuildRequires: pkgconfig(gtk-doc)
|
||||
BuildRequires: glib2-doc
|
||||
BuildRequires: rpm-devel
|
||||
BuildRequires: file-devel
|
||||
%if %{build_python2}
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: python-gobject-base
|
||||
|
|
@ -63,15 +62,15 @@ BuildRequires: python-gobject-base
|
|||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-gobject-base
|
||||
%endif
|
||||
%if 0%{?fedora} >= 40 && 0%{?fedora} < 42
|
||||
# glib2 version with g_once_init_enter_pointer symbol, bug #2265336
|
||||
Requires: glib2 >= 2.79.0-2
|
||||
%endif
|
||||
BuildRequires: help2man
|
||||
|
||||
|
||||
# Patches
|
||||
|
||||
|
||||
%description
|
||||
C library for manipulating module metadata files.
|
||||
See https://github.com/fedora-modularity/libmodulemd/blob/main/README.md for
|
||||
See https://github.com/fedora-modularity/libmodulemd/blob/master/README.md for
|
||||
more details.
|
||||
|
||||
|
||||
|
|
@ -125,6 +124,7 @@ Development files for %{name}.
|
|||
%build
|
||||
%meson \
|
||||
%{meson_accept_overflowed_buildorder_flag} \
|
||||
-Dlibmagic=enabled \
|
||||
-Drpmio=enabled \
|
||||
-Dskip_introspection=false \
|
||||
-Dtest_installed_lib=false \
|
||||
|
|
@ -191,112 +191,16 @@ mv %{buildroot}%{_mandir}/man1/modulemd-validator.1 \
|
|||
|
||||
|
||||
%changelog
|
||||
* Wed Jan 14 2026 Petr Pisar <ppisar@redhat.com> - 2.15.2-5
|
||||
- Adapt tests to glib2-2.87.0 (bug #2423153)
|
||||
|
||||
* Fri Sep 19 2025 Python Maint <python-maint@redhat.com> - 2.15.2-4
|
||||
- Rebuilt for Python 3.14.0rc3 bytecode
|
||||
|
||||
* Fri Aug 15 2025 Python Maint <python-maint@redhat.com> - 2.15.2-3
|
||||
- Rebuilt for Python 3.14.0rc2 bytecode
|
||||
|
||||
* Thu Jul 24 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.2-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
|
||||
|
||||
* Wed Jun 18 2025 Petr Pisar <ppisar@redhat.com> - 2.15.2-1
|
||||
- 2.15.2 bump
|
||||
|
||||
* Tue Jun 03 2025 Python Maint <python-maint@redhat.com> - 2.15.1-2
|
||||
- Rebuilt for Python 3.14
|
||||
|
||||
* Fri May 09 2025 Petr Pisar <ppisar@redhat.com> - 2.15.1-1
|
||||
- 2.15.1 bump
|
||||
|
||||
* Mon Jan 20 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-16
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
|
||||
|
||||
* Fri Jan 17 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-15
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
|
||||
|
||||
* Thu Jul 18 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-14
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
|
||||
|
||||
* Fri Jun 07 2024 Python Maint <python-maint@redhat.com> - 2.15.0-13
|
||||
- Rebuilt for Python 3.13
|
||||
|
||||
* Thu May 16 2024 Petr Pisar <ppisar@redhat.com> - 2.15.0-12
|
||||
- Use canonical "dnf builddep" command in STI tests
|
||||
|
||||
* Wed May 15 2024 Petr Pisar <ppisar@redhat.com> - 2.15.0-11
|
||||
- Do not install Python 2 packages in Fedora STI tests
|
||||
|
||||
* Wed May 15 2024 Petr Pisar <ppisar@redhat.com> - 2.15.0-10
|
||||
- Fix building with glib2-doc 2.80.1 (upstream bug #619)
|
||||
|
||||
* Tue Feb 27 2024 Petr Pisar <ppisar@redhat.com> - 2.15.0-9
|
||||
- Require glib2 version with g_once_init_enter_pointer symbol (bug #2265336)
|
||||
|
||||
* Mon Jan 29 2024 Petr Pisar <ppisar@redhat.com> - 2.15.0-8
|
||||
- Fix building with glib2-doc 2.79.0
|
||||
|
||||
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-7
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.15.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||
|
||||
* Thu Jun 15 2023 Python Maint <python-maint@redhat.com> - 2.15.0-4
|
||||
- Rebuilt for Python 3.12
|
||||
|
||||
* Wed May 10 2023 Florian Festi <ffesti@redhat.com> - 2.15.0-3
|
||||
- Rebuild for rpm-4.18.90
|
||||
|
||||
* Wed May 10 2023 Petr Pisar <ppisar@redhat.com> - 2.15.0-2
|
||||
- Adapt STI tests to current meson
|
||||
|
||||
* Wed May 10 2023 Petr Pisar <ppisar@redhat.com> - 2.15.0-1
|
||||
- 2.15.0 bump
|
||||
|
||||
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.0-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||
|
||||
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 2.14.0-3
|
||||
- Rebuilt for Python 3.11
|
||||
|
||||
* Tue Feb 08 2022 Petr Pisar <ppisar@redhat.com> - 2.14.0-2
|
||||
- Drop removed meson -D developer_build option from CI tests
|
||||
|
||||
* Fri Feb 04 2022 Petr Pisar <ppisar@redhat.com> - 2.14.0-1
|
||||
- 2.14.0 bump
|
||||
|
||||
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.0-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||
|
||||
* Tue Sep 14 2021 Petr Pisar <ppisar@redhat.com> - 2.13.0-3
|
||||
* Tue Sep 14 2021 Petr Pisar <ppisar@redhat.com> - 2.13.0-2
|
||||
- Accept an invalid buildorder 18446744073709551615 found in RHEL 8 repositories
|
||||
(https://pagure.io/koji/issue/3025)
|
||||
|
||||
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jul 09 2021 Petr Pisar <ppisar@redhat.com> - 2.13.0-1
|
||||
- 2.13.0 bump
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 2.12.1-2
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Mon May 03 2021 Petr Pisar <ppisar@redhat.com> - 2.12.1-1
|
||||
- 2.12.1 bump
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.12.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Thu Jan 14 2021 Stephen Gallagher <sgallagh@redhat.com> - 2.12.0-1
|
||||
- Add support for 'buildorder' to Packager documents
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,192 @@
|
|||
From b0dd663edd6ab66ec26c48ff34a52afa040694e6 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
|
||||
Date: Thu, 22 Jul 2021 15:23:55 +0200
|
||||
Subject: [PATCH] Accept 18446744073709551615 buildorder if
|
||||
accept_overflowed_buildorder build boolean is true
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
7c0158bcec05b692d27e37ff46a134f4e294d957 commit (Reject invalid signed
|
||||
integers (rpm buildorder), as found in 2.13.0 release, fortified
|
||||
parsing signed integers.
|
||||
|
||||
It turned out that RHEL 8 delivers a few modules:
|
||||
|
||||
container-tools:rhel8:8020120200601155013:ffd2803a
|
||||
container-tools:rhel8:8030020200923153805:2a301c24
|
||||
container-tools:rhel8:8030020201124131330:830d479e
|
||||
container-tools:rhel8:8030120210208205200:c127ee91
|
||||
|
||||
which contain an invalid buildorder value 18446744073709551615. DNF
|
||||
then warned on loading them into an index and ignored them:
|
||||
|
||||
# dnf module list --repoid pulp-appstream
|
||||
Last metadata expiration check: 3:59:10 ago on Wed 21 Jul 2021 12:38:00 PM CEST.
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 118 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 118 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 107 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 114 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 118 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 118 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 107 col 9]
|
||||
Module yaml error: Failed to parse buildorder in component: 18446744073709551615: The integer value is larger than 9223372036854775807 [line 114 col 9]
|
||||
|
||||
Those were probably built with a broken MBS/libmodulemd which
|
||||
loaded -1 and serialized it as an 64-bit unsigned integer
|
||||
18446744073709551615.
|
||||
|
||||
Because the distributor does not change once-released builds, it
|
||||
became impossible to process them with libmodulemd-2.13.0.
|
||||
|
||||
This patch adds an accept_overflowed_buildorder build option (disabled
|
||||
by default) which enables a workaround to accept 18446744073709551615
|
||||
string as -1 integer when parsing 64-bit signed integers. (The type is
|
||||
used only in buildorder field now).
|
||||
|
||||
(Originally, I developed a more complicated patch only affecting
|
||||
loading while keeping validation strict. But that was not enough for
|
||||
DNF, creareterepo_c and probably many other tools. Thus I prepared
|
||||
even more complicated patch affecting both loading and validation of
|
||||
modulemd formats only (cf. modulemd-packager-v3) and that helped DNF.
|
||||
But the patch ugglified to code to much and considering it's only
|
||||
a temporary hack, I decided for this simple patch which affects
|
||||
loading and validation of all formats.)
|
||||
|
||||
Petr Písař: Ported to 2.13.0 from
|
||||
37a688cc12d7fbab67fda95c47a4605405d7a154.
|
||||
|
||||
Signed-off-by: Petr Písař <ppisar@redhat.com>
|
||||
---
|
||||
meson.build | 1 +
|
||||
meson_options.txt | 3 +++
|
||||
modulemd/meson.build | 2 ++
|
||||
modulemd/modulemd-yaml-util.c | 11 +++++++++++
|
||||
modulemd/tests/test-modulemd-parse_int64.c | 15 ++++++++++++++-
|
||||
5 files changed, 31 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 37792b3..bbb56ba 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -215,6 +215,7 @@ if meson.version().version_compare('>=0.53')
|
||||
'Python 2 Support': get_option('with_py2'),
|
||||
'Python 3 Support': get_option('with_py3'),
|
||||
'Skip Introspection': get_option('skip_introspection'),
|
||||
+ 'Accept overflowed buildorder': get_option('accept_overflowed_buildorder'),
|
||||
'Test Installed Library': get_option('test_installed_lib'),
|
||||
}, section: 'Build Configuration')
|
||||
endif
|
||||
diff --git a/meson_options.txt b/meson_options.txt
|
||||
index 7873d42..3d84459 100644
|
||||
--- a/meson_options.txt
|
||||
+++ b/meson_options.txt
|
||||
@@ -11,6 +11,9 @@
|
||||
#
|
||||
# REMEMBER TO UPDATE THE SUMMARY() IN meson.build when adding options here
|
||||
|
||||
+option('accept_overflowed_buildorder', type : 'boolean', value: 'false',
|
||||
+ description : 'Accept overflowed 18446744073709551615 buildorder as -1. This breaks a specification, but some RHEL 8 module builds look like that.')
|
||||
+
|
||||
option('verbose_tests', type : 'boolean', value : true,
|
||||
description : 'Tests that are run under the "debug" configuration will print all debug messages. Disable this option for valgrind checks, as it speeds it up substantially.')
|
||||
|
||||
diff --git a/modulemd/meson.build b/modulemd/meson.build
|
||||
index 2a60364..0b74818 100644
|
||||
--- a/modulemd/meson.build
|
||||
+++ b/modulemd/meson.build
|
||||
@@ -14,6 +14,7 @@
|
||||
test_installed_lib = get_option('test_installed_lib')
|
||||
skip_introspection = get_option('skip_introspection')
|
||||
verbose_tests = get_option('verbose_tests')
|
||||
+accept_overflowed_buildorder = get_option('accept_overflowed_buildorder')
|
||||
clang_simple_version_script = find_program ('clang_simple_version.sh')
|
||||
|
||||
|
||||
@@ -144,6 +145,7 @@ cdata.set('HAVE_RPMIO', rpm.found())
|
||||
cdata.set('HAVE_LIBMAGIC', magic.found())
|
||||
cdata.set('HAVE_GDATE_AUTOPTR', has_gdate_autoptr)
|
||||
cdata.set('HAVE_EXTEND_AND_STEAL', has_extend_and_steal)
|
||||
+cdata.set('HAVE_OVERFLOWED_BUILDORDER', accept_overflowed_buildorder)
|
||||
configure_file(
|
||||
output : 'config.h',
|
||||
configuration : cdata
|
||||
diff --git a/modulemd/modulemd-yaml-util.c b/modulemd/modulemd-yaml-util.c
|
||||
index 6cbf4cc..ad0bd3c 100644
|
||||
--- a/modulemd/modulemd-yaml-util.c
|
||||
+++ b/modulemd/modulemd-yaml-util.c
|
||||
@@ -11,6 +11,7 @@
|
||||
* For more information on free software, see <https://www.gnu.org/philosophy/free-sw.en.html>.
|
||||
*/
|
||||
|
||||
+#include "config.h"
|
||||
#include "modulemd-errors.h"
|
||||
#include "private/modulemd-subdocument-info-private.h"
|
||||
#include "private/modulemd-util.h"
|
||||
@@ -441,6 +442,16 @@ modulemd_yaml_parse_int64 (yaml_parser_t *parser, GError **error)
|
||||
|
||||
if ((value == G_MAXINT64 && errno == ERANGE))
|
||||
{
|
||||
+#ifdef HAVE_OVERFLOWED_BUILDORDER
|
||||
+ /* A temporary hack. Remove when RHEL 8 goes end of life. */
|
||||
+ if (g_str_equal ((const gchar *)event.data.scalar.value,
|
||||
+ "18446744073709551615"))
|
||||
+ {
|
||||
+ g_debug ("Coercing an invalid signed 64-bit integer to -1: %s",
|
||||
+ (const gchar *)event.data.scalar.value);
|
||||
+ return -1;
|
||||
+ }
|
||||
+#endif
|
||||
g_set_error (error,
|
||||
MODULEMD_YAML_ERROR,
|
||||
MODULEMD_ERROR_VALIDATE,
|
||||
diff --git a/modulemd/tests/test-modulemd-parse_int64.c b/modulemd/tests/test-modulemd-parse_int64.c
|
||||
index 2ccfb53..8759c21 100644
|
||||
--- a/modulemd/tests/test-modulemd-parse_int64.c
|
||||
+++ b/modulemd/tests/test-modulemd-parse_int64.c
|
||||
@@ -11,6 +11,7 @@
|
||||
* For more information on free software, see <https://www.gnu.org/philosophy/free-sw.en.html>.
|
||||
*/
|
||||
|
||||
+#include "config.h"
|
||||
#include <glib.h>
|
||||
#include <locale.h>
|
||||
#include <string.h>
|
||||
@@ -36,7 +37,7 @@ test (const char *input, gint64 expected_value, gboolean expected_error)
|
||||
g_assert_nonnull (error);
|
||||
else
|
||||
g_assert_null (error);
|
||||
- g_assert_cmpuint (parsed, ==, expected_value);
|
||||
+ g_assert_cmpint (parsed, ==, expected_value);
|
||||
}
|
||||
|
||||
static void
|
||||
@@ -69,6 +70,16 @@ test_int64_invalid_too_big (void)
|
||||
test ("9223372036854775808", 0, TRUE);
|
||||
}
|
||||
|
||||
+static void
|
||||
+test_int64_invalid_overflowed (void)
|
||||
+{
|
||||
+#ifdef HAVE_OVERFLOWED_BUILDORDER
|
||||
+ test ("18446744073709551615", -1, FALSE);
|
||||
+#else
|
||||
+ test ("18446744073709551615", 0, TRUE);
|
||||
+#endif
|
||||
+}
|
||||
+
|
||||
static void
|
||||
test_int64_invalid_too_small (void)
|
||||
{
|
||||
@@ -143,6 +154,8 @@ main (int argc, char *argv[])
|
||||
test_int64_invalid_too_big);
|
||||
g_test_add_func ("/modulemd/v2/int64/yaml/parse/invalid_too_small",
|
||||
test_int64_invalid_too_small);
|
||||
+ g_test_add_func ("/modulemd/v2/int64/yaml/parse/invalid_overflowed",
|
||||
+ test_int64_invalid_overflowed);
|
||||
|
||||
g_test_add_func ("/modulemd/v2/uint64/yaml/parse/valid", test_uint64_valid);
|
||||
g_test_add_func ("/modulemd/v2/uint64/yaml/parse/invalid_no_digit",
|
||||
--
|
||||
2.31.1
|
||||
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -1,5 +0,0 @@
|
|||
summary: Sanity tests
|
||||
discover:
|
||||
how: fmf
|
||||
execute:
|
||||
how: tmt
|
||||
4
sources
4
sources
|
|
@ -1,2 +1,2 @@
|
|||
SHA512 (modulemd-2.15.2.tar.xz) = d1785f6982ed19292103d741e3e94581e9789737be6f8e90d19218296f3aeb87d6589f3247744f8eab4f714d298d1508312b119624a8c32086c720becfa4cdc5
|
||||
SHA512 (modulemd-2.15.2.tar.xz.asc) = 282ff35f15418e95aae09d9bff8084aa0b6f2732cea3934a84a1bd4ddd8e50c8375466acb6a39a6e632f4bbbefd49735b7f56e9304d52521786e245f52feae24
|
||||
SHA512 (modulemd-2.13.0.tar.xz) = b2a4fa4120d4dca714ef724a9e8f805d4f8a306a950e670f86f6184467c070ddb93360fff3bb079eb3a442b52024fe796ceb1195800d62bbb1f5cb67f8889e05
|
||||
SHA512 (modulemd-2.13.0.tar.xz.asc) = f588c1333b91db297ab5ec7e67f1d62884d4f58032a75feed1b3c3ff2ae67eb0f13a4209605f4a32d00fe6ccb3561b6fab81c2196f1d4439222b0e141f541ff6
|
||||
|
|
|
|||
32
tests/tests.yml
Normal file
32
tests/tests.yml
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
---
|
||||
- hosts: localhost
|
||||
tags:
|
||||
- classic
|
||||
roles:
|
||||
- role: standard-test-source
|
||||
|
||||
- hosts: localhost
|
||||
tags:
|
||||
- classic
|
||||
tasks:
|
||||
- name: Make sure fedpkg and selinux bindings are installed
|
||||
shell: dnf -y install fedpkg python{2,3}-libselinux libmodulemd-devel --skip-broken
|
||||
- name: Copy spec file to remote machine
|
||||
copy:
|
||||
src: "{{ playbook_dir }}/../libmodulemd.spec"
|
||||
dest: /tmp/libmodulemd.spec
|
||||
- name: Install build deps
|
||||
shell: dnf -y build-dep /tmp/libmodulemd.spec
|
||||
|
||||
- hosts: localhost
|
||||
tags:
|
||||
- classic
|
||||
roles:
|
||||
- role: standard-test-basic
|
||||
tests:
|
||||
- build:
|
||||
dir: .
|
||||
run: meson -Daccept_overflowed_buildorder=true -Dlibmagic=enabled -Drpmio=enabled -Dskip_introspection=false -Dtest_installed_lib=true -Dwith_py2=false -Dwith_py3=true -Ddeveloper_build=false source
|
||||
- unittests:
|
||||
dir: .
|
||||
run: ninja test
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
summary: Upstream tests
|
||||
component: libmodulemd
|
||||
require:
|
||||
- bash
|
||||
- dnf5
|
||||
- dnf5-command(builddep)
|
||||
- fedpkg
|
||||
- libmodulemd
|
||||
- koji
|
||||
- meson
|
||||
- ninja
|
||||
- rpm
|
||||
- rpmdevtools
|
||||
duration: 10m
|
||||
test: ./upstream-tests.sh
|
||||
|
|
@ -1,26 +0,0 @@
|
|||
#!/bin/bash
|
||||
set -ex
|
||||
DIR=$(mktemp -d)
|
||||
pushd "$DIR"
|
||||
|
||||
SRCRPM=$(rpm -q --qf '%{sourcerpm}' libmodulemd)
|
||||
koji download-build -a src "$SRCRPM"
|
||||
rpmdev-extract "$SRCRPM"
|
||||
|
||||
NAME=$(rpm -q --qf %{name} "$SRCRPM")
|
||||
VERSION=$(rpm -q --qf %{version} "$SRCRPM")
|
||||
pushd "${SRCRPM//.rpm}"
|
||||
dnf -y builddep "$NAME".spec
|
||||
fedpkg prep
|
||||
|
||||
meson setup -Daccept_overflowed_buildorder=true -Drpmio=enabled \
|
||||
-Dskip_introspection=false -Dtest_installed_lib=true \
|
||||
-Dwith_py2=false -Dwith_py3=true \
|
||||
./build "${NAME}-${VERSION}-build/modulemd-${VERSION}"
|
||||
ninja -C ./build
|
||||
meson test -C ./build
|
||||
|
||||
popd
|
||||
|
||||
popd
|
||||
rm -r "$DIR"
|
||||
Loading…
Add table
Add a link
Reference in a new issue