mirror of
https://github.com/anchore/syft.git
synced 2026-02-12 02:26:42 +01:00
chore: ignore .DS_Store in test fixtures (#4422)
Otherwise, we get test failures on macOS if macOS has decided to put .DS_Store entries in the test fixtures. Signed-off-by: Will Murphy <willmurphyscode@users.noreply.github.com>
This commit is contained in:
parent
5b96d1d69d
commit
a0f7148608
@ -174,7 +174,7 @@ func getLogicalKey(managedBinaryPath string) (*LogicalEntryKey, error) {
|
|||||||
func allFilePaths(root string) ([]string, error) {
|
func allFilePaths(root string) ([]string, error) {
|
||||||
var paths []string
|
var paths []string
|
||||||
err := filepath.Walk(root, func(path string, info os.FileInfo, _ error) error {
|
err := filepath.Walk(root, func(path string, info os.FileInfo, _ error) error {
|
||||||
if info != nil && !info.IsDir() && !strings.HasSuffix(path, digestFileSuffix) {
|
if info != nil && !info.IsDir() && !strings.HasSuffix(path, digestFileSuffix) && !strings.HasSuffix(path, ".DS_Store") {
|
||||||
paths = append(paths, path)
|
paths = append(paths, path)
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user