From 6fb3a876a89826198d388ac942889e2c09bcb9d7 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Tue, 19 May 2020 09:29:02 -0400 Subject: [PATCH] tests: replace Entry with DpkgMetadata name Signed-off-by: Alfredo Deza --- imgbom/analyzer/dpkg/parser_test.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/imgbom/analyzer/dpkg/parser_test.go b/imgbom/analyzer/dpkg/parser_test.go index 0492b9e58..0704c54ae 100644 --- a/imgbom/analyzer/dpkg/parser_test.go +++ b/imgbom/analyzer/dpkg/parser_test.go @@ -5,10 +5,11 @@ import ( "os" "testing" + "github.com/anchore/imgbom/imgbom/pkg" "github.com/go-test/deep" ) -func compareEntries(t *testing.T, left, right Entry) { +func compareEntries(t *testing.T, left, right pkg.DpkgMetadata) { t.Helper() if diff := deep.Equal(left, right); diff != nil { t.Error(diff) @@ -18,11 +19,11 @@ func compareEntries(t *testing.T, left, right Entry) { func TestSinglePackage(t *testing.T) { tests := []struct { name string - expected Entry + expected pkg.DpkgMetadata }{ { name: "Test Single Package", - expected: Entry{ + expected: pkg.DpkgMetadata{ Package: "apt", Status: "install ok installed", Priority: "required", @@ -73,11 +74,11 @@ func TestSinglePackage(t *testing.T) { func TestMultiplePackages(t *testing.T) { tests := []struct { name string - expected []Entry + expected []pkg.DpkgMetadata }{ { name: "Test Multiple Package", - expected: []Entry{ + expected: []pkg.DpkgMetadata{ { Package: "tzdata", Status: "install ok installed",