diff --git a/internal/linux/arch.go b/internal/linux/arch.go index 363f3d103..62ce399ea 100644 --- a/internal/linux/arch.go +++ b/internal/linux/arch.go @@ -13,8 +13,10 @@ func Arch(key string) string { return "i386" case "amd64": return "amd64" - case "arm6": // GOARCH + GOARM + case "arm5": // GOARCH + GOARM return "armel" + case "arm6": // GOARCH + GOARM + return "armhf" case "arm7": // GOARCH + GOARM return "armhf" } diff --git a/internal/linux/arch_test.go b/internal/linux/arch_test.go index a8d9901af..8b689c04a 100644 --- a/internal/linux/arch_test.go +++ b/internal/linux/arch_test.go @@ -9,14 +9,15 @@ import ( func TestArch(t *testing.T) { for from, to := range map[string]string{ - "linuxamd64": "amd64", - "linux386": "i386", - "linuxarm64": "arm64", - "linuxarm6": "armel", - "linuxarm7": "armhf", - "linuxppc64": "ppc64", - "linuxppc64le": "ppc64le", - "linuxwhat": "what", + "linuxamd64": "amd64", + "linux386": "i386", + "linuxarm64": "arm64", + "linuxarm5": "armel", + "linuxarm6": "armhf", + "linuxarm7": "armhf", + "linuxppc64": "ppc64", + "linuxppc64le": "ppc64le", + "linuxwhat": "what", } { t.Run(fmt.Sprintf("%s to %s", from, to), func(t *testing.T) { assert.Equal(t, to, Arch(from)) diff --git a/internal/pipe/snapcraft/snapcraft_test.go b/internal/pipe/snapcraft/snapcraft_test.go index 4a2fc5ea9..d01376977 100644 --- a/internal/pipe/snapcraft/snapcraft_test.go +++ b/internal/pipe/snapcraft/snapcraft_test.go @@ -80,7 +80,7 @@ func TestRunPipe(t *testing.T) { addBinaries(t, ctx, "foo", filepath.Join(dist, "foo"), "foo") addBinaries(t, ctx, "bar", filepath.Join(dist, "bar"), "bar") assert.NoError(t, Pipe{}.Run(ctx)) - assert.Len(t, ctx.Artifacts.Filter(artifact.ByType(artifact.PublishableSnapcraft)).List(), 6) + assert.Len(t, ctx.Artifacts.Filter(artifact.ByType(artifact.PublishableSnapcraft)).List(), 9) } func TestRunPipeInvalidNameTemplate(t *testing.T) {