Skip to content

Commit

Permalink
add s390x support
Browse files Browse the repository at this point in the history
Signed-off-by: Yan Song Liu <[email protected]>
  • Loading branch information
Yan Song Liu committed Mar 19, 2024
1 parent 29c8a21 commit de0747e
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ jobs:
env:
DOCKER_CLI_EXPERIMENTAL: "enabled"
NO_TEST_PPC64LE: "true"
NO_TEST_S390X: "true"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
Expand Down
1 change: 1 addition & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ builds:
- amd64
- arm64
- ppc64le
- s390
mod_timestamp: "{{ .CommitTimestamp }}"
flags:
- -trimpath
Expand Down
21 changes: 21 additions & 0 deletions acceptance_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ func TestCore(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}
accept(t, acceptParms{
Name: fmt.Sprintf("%s_%s", testName, testArch),
Conf: fmt.Sprintf("core.%s.yaml", testName),
Expand Down Expand Up @@ -81,6 +84,9 @@ func TestUpgrade(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}

arch := strings.ReplaceAll(testArch, "armv", "arm/")
oldpkg := fmt.Sprintf("tmp/%s_%s.v1.%s", testName, testArch, testFormat)
Expand Down Expand Up @@ -144,6 +150,9 @@ func TestRPMCompression(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}
accept(t, acceptParms{
Name: fmt.Sprintf("%s_compression_%s", testCompFormat, testArch),
Conf: fmt.Sprintf("rpm.%s.compression.yaml", testCompFormat),
Expand Down Expand Up @@ -173,6 +182,9 @@ func TestDebCompression(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}

target := "compression"
if testCompFormat == "zstd" {
Expand Down Expand Up @@ -212,6 +224,9 @@ func TestRPMSpecific(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}
accept(t, acceptParms{
Name: fmt.Sprintf("%s_%s", testName, testArch),
Conf: fmt.Sprintf("%s.%s.yaml", format, testName),
Expand Down Expand Up @@ -245,6 +260,9 @@ func TestDebSpecific(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}
accept(t, acceptParms{
Name: fmt.Sprintf("%s_%s", testName, testArch),
Conf: fmt.Sprintf("%s.%s.yaml", format, testName),
Expand Down Expand Up @@ -295,6 +313,9 @@ func TestDebSign(t *testing.T) {
if testArch == "ppc64le" && os.Getenv("NO_TEST_PPC64LE") == "true" {
t.Skip("ppc64le arch not supported in pipeline")
}
if testArch == "s390" && os.Getenv("NO_TEST_S390X") == "true" {
t.Skip("s390x arch not supported in pipeline")
}
accept(t, acceptParms{
Name: fmt.Sprintf("%s_sign_%s", testSigtype, testArch),
Conf: fmt.Sprintf("deb.%s.sign.yaml", testSigtype),
Expand Down

0 comments on commit de0747e

Please sign in to comment.