import weldr-client-35.5-2.el9

This commit is contained in:
CentOS Sources 2022-04-05 06:11:49 -04:00 committed by Stepan Oksanichenko
parent 34f542c04e
commit 37c2de3867
6 changed files with 50 additions and 160 deletions

2
.gitignore vendored
View File

@ -1,2 +1,2 @@
SOURCES/gpg-117E8C168EFE3A7F.key
SOURCES/weldr-client-35.2.tar.gz
SOURCES/weldr-client-35.5.tar.gz

View File

@ -1,2 +1,2 @@
9a95f2c777b4fca2c9c5705ed330cafcf1b09555 SOURCES/gpg-117E8C168EFE3A7F.key
fd9aaab62c5ee5c44704b815b8690fbb5d2db199 SOURCES/weldr-client-35.2.tar.gz
089128c30d8aa218304d0bb8d571f9a6d45aba72 SOURCES/weldr-client-35.5.tar.gz

View File

@ -1,74 +0,0 @@
From edeafc1b677eb0f362fdb60fbb624ad8e1632c21 Mon Sep 17 00:00:00 2001
From: "Brian C. Lane" <bcl@redhat.com>
Date: Wed, 25 Aug 2021 09:00:48 -0700
Subject: [PATCH] tests: Fix integration tests
osbuild-composer v31 returns a more detailed error for
TestStartComposeBadType, so that has been changed.
The number of image types returned depends on the distribution being
used, so change to looking for >= 6 of them.
The source type depends on the first repo in the list, so it could be
any of the supported types. They all start with "yum-" so change the
test to look for that instead.
---
weldr/compose_test.go | 6 +++---
weldr/sources_test.go | 3 ++-
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/weldr/compose_test.go b/weldr/compose_test.go
index 7479edf..fda6953 100644
--- a/weldr/compose_test.go
+++ b/weldr/compose_test.go
@@ -30,7 +30,7 @@ func TestGetComposeTypes(t *testing.T) {
require.Nil(t, err)
require.Nil(t, r)
require.NotNil(t, types)
- assert.Equal(t, 6, len(types))
+ assert.GreaterOrEqual(t, len(types), 6)
assert.Contains(t, types, "openstack")
}
@@ -44,7 +44,7 @@ func TestGetComposeTypesDistro(t *testing.T) {
require.Nil(t, err)
require.Nil(t, r)
require.NotNil(t, types)
- assert.Equal(t, 6, len(types))
+ assert.GreaterOrEqual(t, len(types), 6)
assert.Contains(t, types, "openstack")
}
@@ -141,7 +141,7 @@ func TestStartComposeBadType(t *testing.T) {
require.Nil(t, err)
require.NotNil(t, r)
assert.False(t, r.Status)
- assert.Equal(t, APIErrorMsg{"UnknownComposeType", "Unknown compose type for architecture: punchcard"}, r.Errors[0])
+ assert.Equal(t, APIErrorMsg{"ComposeError", "Failed to get compose type \"punchcard\": invalid image type: punchcard"}, r.Errors[0])
}
func TestStartComposeBadDepsolve(t *testing.T) {
diff --git a/weldr/sources_test.go b/weldr/sources_test.go
index 77eb357..18b00f1 100644
--- a/weldr/sources_test.go
+++ b/weldr/sources_test.go
@@ -7,6 +7,7 @@
package weldr
import (
+ "strings"
"testing"
"github.com/stretchr/testify/assert"
@@ -40,7 +41,7 @@ func TestGetSourcesJSON(t *testing.T) {
assert.Equal(t, names[0], id)
sourceType, ok := sources[names[0]].(map[string]interface{})["type"].(string)
require.True(t, ok)
- assert.Equal(t, "yum-metalink", sourceType)
+ assert.True(t, strings.HasPrefix(sourceType, "yum-"))
}
func TestGetSourcesJSONError(t *testing.T) {
--
2.31.1

View File

@ -1,11 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQEzBAABCgAdFiEEtMa0UeT6i0IyyhkeEX6MFo7+On8FAmEj7bEACgkQEX6MFo7+
On92OQf/R5g0eRQd0eiDY7jiq+5j1WIVK1OaVTFduo8RhqaK08gfwW8Z51wi3bu4
yyO6MriYN230x5ZBcEgbnVmjDQIl2HLqTEFpGAyNEuh/bHVNNeNT6dAkcexoUb8N
Rwe6KWm/0vwxkD2X7WI+WlCLp0cNJ+foLbkZ1sMeNaHekuJCRAPDQkdEN/nwFn5M
ZPgH1bSS2XBkg8JbNwEFfWcjGlPfmPHJMv1+1i/W0EAp7/uYbPz+FEX0W/aXQ7fI
l/KxFq8Tt+Zk2qIw+XN9dzV2E2ngayvsM3Vm5igTl+HMRIe5Ro3RuFHp3HbFmZ8M
xqXZS0aSbMBqv4TQEtsnnXku9SusVQ==
=8+eY
-----END PGP SIGNATURE-----

View File

@ -0,0 +1,11 @@
-----BEGIN PGP SIGNATURE-----
iQEzBAABCgAdFiEEtMa0UeT6i0IyyhkeEX6MFo7+On8FAmIK0YcACgkQEX6MFo7+
On8CfAf7BSNtG3oQKc9KxmN+D7hS/IHliKpAWRhF+kNZDshytLZeISuB8yjDlXJ8
LMVifzmkumoZTwYsk74TGJjL/j/wTo6RAE5+OEIQIftvidihahNUH5WM6XrbSVAA
ygB3NgrhaGTnk8TRHNNnY26CJ6drY6MTNB3V+JFXtVlx/EgH+LHHLrXOA6f5I+3h
TKMzxJOXgXb1yDrSdVJYj1IToGmwT+QsiCmzciYCykshRaoe9hGfrDPoC4xGjdVx
OreX9x/tmPuPqQhXK40CqVX2rGMzjMf78/01dDiWHatOKepHdGy0N7VFwLQ8/f0Q
QD0Yq3i0JMzzS28NAszNdQdIeAD7BA==
=A1hY
-----END PGP SIGNATURE-----

View File

@ -3,10 +3,10 @@
# Pass --without signed to skip gpg signed tar.gz (DO NOT DO THAT IN PRODUCTION)
%bcond_without signed
%global goipath github.com/osbuild/weldr-client
%global goipath github.com/osbuild/weldr-client/v2
Name: weldr-client
Version: 35.2
Version: 35.5
Release: 2%{?dist}
# Upstream license specification: Apache-2.0
License: ASL 2.0
@ -18,8 +18,6 @@ Source1: https://github.com/osbuild/weldr-client/releases/download/v%{version}
Source2: https://keys.openpgp.org/vks/v1/by-fingerprint/117E8C168EFE3A7F#/gpg-117E8C168EFE3A7F.key
%endif
Patch0001: 0001-tests-Fix-integration-tests.patch
Obsoletes: composer-cli < 35.0
Provides: composer-cli = %{version}-%{release}
@ -53,6 +51,8 @@ Command line utility to control osbuild-composer
%endif
%build
export LDFLAGS="-X %{goipath}/cmd/composer-cli/root.Version=%{version} "
%if 0%{?rhel}
GO_BUILD_PATH=$PWD/_build
install -m 0755 -vd $(dirname $GO_BUILD_PATH/src/%{goipath})
@ -66,28 +66,23 @@ export GOFLAGS=-mod=vendor
export GOPATH="%{gobuilddir}:${GOPATH:+${GOPATH}:}%{?gopath}"
export GO111MODULE=off
%endif
%gobuild -o composer-cli %{goipath}/cmd/composer-cli
export LDFLAGS="-X github.com/osbuild/weldr-client/cmd/composer-cli/root.Version=%{version} "
make GOBUILDFLAGS="%{gobuildflags}" build
## TODO
##make man
%if %{with tests} || 0%{?rhel}
export BUILDTAGS="integration"
# Build test binaries with `go test -c`, so that they can take advantage of
# golang's testing package. The golang rpm macros don't support building them
# golang's testing package. The RHEL golang rpm macros don't support building them
# directly. Thus, do it manually, taking care to also include a build id.
#
# On Fedora, also turn off go modules and set the path to the one into which
# On Fedora go modules have already been turned off, and the path set to the one into which
# the golang-* packages install source code.
%if 0%{?fedora}
export GOPATH="%{gobuilddir}:${GOPATH:+${GOPATH}:}%{?gopath}"
export GO111MODULE=off
%endif
export LDFLAGS="-X github.com/osbuild/weldr-client/cmd/composer-cli/root.Version=%{version} "
export BUILDTAGS="integration"
make GOBUILDFLAGS="%{gobuildflags}" integration
export LDFLAGS="${LDFLAGS:-} -linkmode=external -compressdwarf=false -B 0x$(od -N 20 -An -tx1 -w100 /dev/urandom | tr -d ' ')"
go test -c -tags=integration -buildmode pie -compiler gc -ldflags="${LDFLAGS}" -o composer-cli-tests %{goipath}/weldr
%endif
%install
@ -103,8 +98,10 @@ export GOPATH="%{gobuilddir}:${GOPATH:+${GOPATH}:}%{?gopath}"
export GO111MODULE=off
%endif
export LDFLAGS="-X github.com/osbuild/weldr-client/cmd/composer-cli/root.Version=%{version} "
make GOBUILDFLAGS="%{gotestflags}" test
# Run the unit tests
export LDFLAGS="-X %{goipath}/cmd/composer-cli/root.Version=%{version} "
make test
%files
%license LICENSE
@ -129,59 +126,26 @@ composer-cli package.
%changelog
* Wed Aug 25 2021 Brian C. Lane <bcl@redhat.com> - 35.2-2
- gating: Add gating tests
Resolves: rhbz#1996788
- gating: Workaround to install latest packages
- Fix integration tests
* Wed Feb 16 2022 Brian C. Lane <bcl@redhat.com> - 35.5-2
- Switch to tmt tests instead of STI and update repo urls
Related: rhbz#2052601
* Mon Aug 23 2021 Brian C. Lane <bcl@redhat.com> - 35.2-1
- New release: 35.2 (bcl)
Resolves: rhbz#1996762
- weldr: Use assert.Contains instead of IsStringInSlice (bcl)
- Add missing projects depsolve command (bcl)
- Add support for projects info --distro=DISTRO-NAME (bcl)
- Add support for projects list --distro=DISTRO-NAME (bcl)
- Add support for modules info --distro=DISTRO-NAME (bcl)
- weldr: Add distros to testState (bcl)
- Add support for modules list --distro=DISTRO-NAME (bcl)
- weldr: Add AppendQuery helper function (bcl)
- Add support for compose types --distro=DISTRO-NAME (bcl)
- composer-cli: Add distros list command (bcl)
- weldr: Add ListDistros function and tests (bcl)
- Makefile: Add scratch-srpm and scratch-rpm targets (bcl)
- Print filename for compose results (bcl)
- ExcuteTests - return the correct error variables in case of errors (atodorov)
- The rpm package should obsolete composer-cli from lorax (bcl)
- tests: Enable CodeCov.io (atodorov)
- actions: Install lint using GOPATH (bcl)
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 35.1-4
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Tue Jun 22 2021 Mohan Boddu <mboddu@redhat.com> - 35.1-3
- Rebuilt for RHEL 9 BETA for openssl 3.0
Related: rhbz#1971065
* Thu Apr 22 2021 Brian C. Lane <bcl@redhat.com> - 35.1-2
- Obsolete composer-cli < 35.0 instead of 34.0
Patch until next upstream release
* Mon Apr 12 2021 Brian C. Lane <bcl@redhat.com> - 35.1-1
- New release: 35.1 (bcl)
- spec: Change release back to 1 (bcl)
- spec: Move testify BuildRequires into fedora block (bcl)
- vendor: Add vendored dependencies for RHEL (bcl)
- tools: Add prepare-source.sh vendoring helper script (bcl)
- Makefile: skip vendor directory for check target (bcl)
- spec: Bump release to 2 (bcl)
- spec: Fix BuildRequires for tests (bcl)
- Makefile: Remove executable from bash completion (bcl)
- Makefile: Only use GOBUILDFLAGS (bcl)
- spec: Bump release to 2 (bcl)
- spec: Add doc files (bcl)
- spec: Add gpg signature verification (bcl)
- spec: Use git-core instead of git (bcl)
- spec: Set License to Apache 2.0 (bcl)
- spec: Update Source urls with new project location (bcl)
* Tue Feb 15 2022 Brian C. Lane <bcl@redhat.com> - 35.5-1
- New release: 35.5 (bcl)
Resolves: rhbz#2052601
- docs: Explain how to undo blueprints delete (bcl)
- test: server status no longer returns devel (bcl)
- Use GetFrozenBlueprintsTOML for blueprints freeze save (bcl)
- Add a test for float uid/gid in frozen blueprint (bcl)
- Use GetBlueprintsTOML for blueprints save (bcl)
- test: Add a test for float uid/gid in saved blueprint (bcl)
- build(deps): bump github.com/BurntSushi/toml from 0.4.1 to 1.0.0 (49699333+dependabot[bot])
- tests: trigger on push to main (jrusz)
- build(deps): bump github.com/spf13/cobra from 1.2.1 to 1.3.0 (49699333+dependabot[bot])
- ci: add keystore for sonarqube (jrusz)
- spec: Switch to using %%gobuild macro on Fedora (bcl)
- ci: change workflow name (jrusz)
- ci: add gitlab-ci and sonarqube (jrusz)
- doc: fix example links from the README (tdecacqu)
- build(deps): bump actions/checkout from 2.3.4 to 2.4.0 (49699333+dependabot[bot])
- ci: Enable Coverity Scan tool (atodorov)