mirror of
https://src.fedoraproject.org/rpms/module-build-service.git
synced 2026-11-03 14:43:44 +08:00
backport few patches to fix skiptests behavior
Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
27
0001-manager-skiptests-is-not-positional-argument.patch
Normal file
27
0001-manager-skiptests-is-not-positional-argument.patch
Normal file
@@ -0,0 +1,27 @@
|
||||
From 99a6c03507e496df67c9f2eecd0585e891fb0ad4 Mon Sep 17 00:00:00 2001
|
||||
From: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||||
Date: Sun, 3 Sep 2017 13:20:37 +0200
|
||||
Subject: [PATCH] manager: skiptests is not positional argument
|
||||
|
||||
mbs-build adds --skiptests option, but mbs-manager thinks that skiptests
|
||||
is positional argument.
|
||||
|
||||
Fixes: aac4227eb83b8146487c415fee4267d22baad506
|
||||
Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||||
---
|
||||
module_build_service/manage.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/module_build_service/manage.py b/module_build_service/manage.py
|
||||
index 2e76424..e915f7d 100755
|
||||
--- a/module_build_service/manage.py
|
||||
+++ b/module_build_service/manage.py
|
||||
@@ -118,7 +118,7 @@ def cleardb():
|
||||
|
||||
@manager.option('branch')
|
||||
@manager.option('url')
|
||||
-@manager.option('skiptests', action='store_true')
|
||||
+@manager.option('--skiptests', action='store_true')
|
||||
@manager.option('-l', '--add-local-build', action='append', default=None, dest='local_build_nsvs')
|
||||
def build_module_locally(url, branch, local_build_nsvs=None, skiptests=False):
|
||||
""" Performs local module build using Mock
|
||||
@@ -0,0 +1,32 @@
|
||||
From ee1176f444571f98132393c65e800d1c128831f7 Mon Sep 17 00:00:00 2001
|
||||
From: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||||
Date: Sun, 3 Sep 2017 12:22:11 +0200
|
||||
Subject: [PATCH] utils: unbreak building packages when tests are skipped
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Just replacing %check macro is ¤&%¤#%&¤%¤. I'm not going to
|
||||
add any more words on it.
|
||||
|
||||
It breaks building many packages.
|
||||
|
||||
Fixes: 5391e7c9afb709a5bed0d920d0cc9e346537976c
|
||||
Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
|
||||
---
|
||||
module_build_service/utils.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/module_build_service/utils.py b/module_build_service/utils.py
|
||||
index 9d6d173..70dbe14 100644
|
||||
--- a/module_build_service/utils.py
|
||||
+++ b/module_build_service/utils.py
|
||||
@@ -908,7 +908,7 @@ def submit_module_build_from_scm(username, url, branch, allow_local_url=False,
|
||||
url = "file://" + url
|
||||
mmd, scm, yaml = _fetch_mmd(url, branch, allow_local_url)
|
||||
if skiptests:
|
||||
- mmd.buildopts.rpms.macros += "\n\n%check exit 0\n"
|
||||
+ mmd.buildopts.rpms.macros += "\n\n%__spec_check_pre exit 0\n"
|
||||
return submit_module_build(username, url, mmd, scm, yaml, optional_params)
|
||||
|
||||
|
||||
@@ -10,6 +10,10 @@ URL: https://pagure.io/fm-orchestrator
|
||||
Source0: https://files.pythonhosted.org/packages/source/m/%{name}/%{name}-%{version}.tar.gz
|
||||
Patch0: mbs-no-mbsbuild.patch
|
||||
Patch1: mbs-build-trailing-slash.patch
|
||||
# https://pagure.io/fm-orchestrator/pull-request/662
|
||||
Patch2: 0001-utils-unbreak-building-packages-when-tests-are-skipp.patch
|
||||
# https://pagure.io/fm-orchestrator/pull-request/663
|
||||
Patch3: 0001-manager-skiptests-is-not-positional-argument.patch
|
||||
|
||||
%if 0%{?rhel} && 0%{?rhel} <= 7
|
||||
# In EL7 we need flask which needs python-itsdangerous which comes from
|
||||
|
||||
Reference in New Issue
Block a user