Skip to content

Commit

Permalink
Update tests to not fail on Mac M1's. (#1730)
Browse files Browse the repository at this point in the history
Closes #1673

Signed-off-by: Shane Dell <shanedell100@gmail.com>
  • Loading branch information
shanedell authored Apr 12, 2023
1 parent dd30c99 commit 661d256
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions syft/source/image_all_layers_resolver_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package source

import (
"fmt"
"io"
"runtime"
"sort"
"testing"

Expand Down Expand Up @@ -689,6 +691,11 @@ func Test_imageAllLayersResolver_resolvesLinks(t *testing.T) {
func TestAllLayersResolver_AllLocations(t *testing.T) {
img := imagetest.GetFixtureImage(t, "docker-archive", "image-files-deleted")

arch := "x86_64"
if runtime.GOARCH == "arm64" {
arch = "aarch64"
}

resolver, err := newAllLayersResolver(img)
assert.NoError(t, err)

Expand Down Expand Up @@ -799,9 +806,9 @@ func TestAllLayersResolver_AllLocations(t *testing.T) {
"/lib/apk/db/triggers",
"/lib/apk/exec",
"/lib/firmware",
"/lib/ld-musl-x86_64.so.1",
fmt.Sprintf("/lib/ld-musl-%s.so.1", arch),
"/lib/libapk.so.3.12.0",
"/lib/libc.musl-x86_64.so.1",
fmt.Sprintf("/lib/libc.musl-%s.so.1", arch),
"/lib/libcrypto.so.3",
"/lib/libssl.so.3",
"/lib/libz.so.1",
Expand Down

0 comments on commit 661d256

Please sign in to comment.