From f87a33c622241a101c29c403ce3f0a1acd98f32f Mon Sep 17 00:00:00 2001 From: Daniele Pensiero Date: Tue, 19 Oct 2021 13:04:38 +0200 Subject: [PATCH] fixed impact type --- testdata/testdata.go | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/testdata/testdata.go b/testdata/testdata.go index 1eb083b89..fac35a78b 100644 --- a/testdata/testdata.go +++ b/testdata/testdata.go @@ -216,10 +216,10 @@ var ( Reason: RuleErrorKey1.Reason, Resolution: RuleErrorKey1.Resolution, MoreInfo: RuleErrorKey1.MoreInfo, - TotalRisk: (RuleErrorKey1.Impact + RuleErrorKey1.Likelihood) / 2, + TotalRisk: (RuleErrorKey1.Impact.Impact + RuleErrorKey1.Likelihood) / 2, Metadata: types.ErrorKeyMetadata{ Description: RuleErrorKey1.Description, - Impact: RuleErrorKey1.Impact, + Impact: RuleErrorKey1.Impact.Impact, Likelihood: RuleErrorKey1.Likelihood, PublishDate: timeToStr(RuleErrorKey1.PublishDate), Status: statusToStr(RuleErrorKey1.Active), @@ -247,10 +247,10 @@ var ( Reason: RuleErrorKey2.Reason, Resolution: RuleErrorKey2.Resolution, MoreInfo: RuleErrorKey2.MoreInfo, - TotalRisk: (RuleErrorKey2.Impact + RuleErrorKey2.Likelihood) / 2, + TotalRisk: (RuleErrorKey2.Impact.Impact + RuleErrorKey2.Likelihood) / 2, Metadata: types.ErrorKeyMetadata{ Description: RuleErrorKey2.Description, - Impact: RuleErrorKey2.Impact, + Impact: RuleErrorKey2.Impact.Impact, Likelihood: RuleErrorKey2.Likelihood, PublishDate: timeToStr(RuleErrorKey2.PublishDate), Status: statusToStr(RuleErrorKey2.Active), @@ -278,10 +278,10 @@ var ( Reason: RuleErrorKey3.Reason, Resolution: RuleErrorKey3.Resolution, MoreInfo: RuleErrorKey3.MoreInfo, - TotalRisk: (RuleErrorKey3.Impact + RuleErrorKey3.Likelihood) / 2, + TotalRisk: (RuleErrorKey3.Impact.Impact + RuleErrorKey3.Likelihood) / 2, Metadata: types.ErrorKeyMetadata{ Description: RuleErrorKey3.Description, - Impact: RuleErrorKey3.Impact, + Impact: RuleErrorKey3.Impact.Impact, Likelihood: RuleErrorKey3.Likelihood, PublishDate: timeToStr(RuleErrorKey3.PublishDate), Status: statusToStr(RuleErrorKey3.Active), @@ -309,10 +309,10 @@ var ( Reason: RuleErrorKey4.Reason, Resolution: RuleErrorKey4.Resolution, MoreInfo: RuleErrorKey4.MoreInfo, - TotalRisk: (RuleErrorKey4.Impact + RuleErrorKey4.Likelihood) / 2, + TotalRisk: (RuleErrorKey4.Impact.Impact + RuleErrorKey4.Likelihood) / 2, Metadata: types.ErrorKeyMetadata{ Description: RuleErrorKey4.Description, - Impact: RuleErrorKey4.Impact, + Impact: RuleErrorKey4.Impact.Impact, Likelihood: RuleErrorKey4.Likelihood, PublishDate: "2019-10-29 15:00:00", Status: statusToStr(RuleErrorKey4.Active), @@ -340,10 +340,10 @@ var ( Reason: RuleErrorKey5.Reason, Resolution: RuleErrorKey5.Resolution, MoreInfo: RuleErrorKey5.MoreInfo, - TotalRisk: (RuleErrorKey5.Impact + RuleErrorKey5.Likelihood) / 2, + TotalRisk: (RuleErrorKey5.Impact.Impact + RuleErrorKey5.Likelihood) / 2, Metadata: types.ErrorKeyMetadata{ Description: RuleErrorKey5.Description, - Impact: RuleErrorKey5.Impact, + Impact: RuleErrorKey5.Impact.Impact, Likelihood: RuleErrorKey5.Likelihood, PublishDate: timeToStr(RuleErrorKey5.PublishDate), Status: statusToStr(RuleErrorKey5.Active), @@ -441,7 +441,7 @@ var ( ErrorKey: RuleErrorKey1.ErrorKey, Condition: RuleErrorKey1.Condition, Description: RuleErrorKey1.Description, - TotalRisk: (RuleErrorKey1.Impact + RuleErrorKey1.Likelihood) / 2, + TotalRisk: (RuleErrorKey1.Impact.Impact + RuleErrorKey1.Likelihood) / 2, PublishDate: RuleErrorKey1.PublishDate, Active: RuleErrorKey1.Active, Generic: RuleErrorKey1.Generic, @@ -457,7 +457,7 @@ var ( ErrorKey: RuleErrorKey2.ErrorKey, Condition: RuleErrorKey2.Condition, Description: RuleErrorKey2.Description, - TotalRisk: (RuleErrorKey2.Impact + RuleErrorKey2.Likelihood) / 2, + TotalRisk: (RuleErrorKey2.Impact.Impact + RuleErrorKey2.Likelihood) / 2, PublishDate: RuleErrorKey2.PublishDate, Active: RuleErrorKey2.Active, Generic: RuleErrorKey2.Generic, @@ -473,7 +473,7 @@ var ( ErrorKey: RuleErrorKey3.ErrorKey, Condition: RuleErrorKey3.Condition, Description: RuleErrorKey3.Description, - TotalRisk: (RuleErrorKey3.Impact + RuleErrorKey3.Likelihood) / 2, + TotalRisk: (RuleErrorKey3.Impact.Impact + RuleErrorKey3.Likelihood) / 2, PublishDate: RuleErrorKey3.PublishDate, Active: RuleErrorKey3.Active, Generic: RuleErrorKey3.Generic,