mirror of
https://github.com/slsa-framework/slsa-verifier.git
synced 2026-08-19 03:26:20 +00:00
update (#244)
This commit is contained in:
@@ -175,8 +175,8 @@ func (self *Provenance) VerifyTextProvenance() error {
|
||||
}
|
||||
|
||||
// Note: DeepEqual() has problem with time comparisons: https://github.com/onsi/gomega/issues/264
|
||||
// but this should not affect us since both times are supposed to have the the same string and
|
||||
// they are both taken from a strng representation.
|
||||
// but this should not affect us since both times are supposed to have the same string and
|
||||
// they are both taken from a string representation.
|
||||
// We do not use cmp.Equal() because it *can* panic and is intended for unit tests only.
|
||||
if !reflect.DeepEqual(unverifiedTextIntotoStatement, *self.verifiedIntotoStatement) {
|
||||
return fmt.Errorf("%w: diff '%s'", serrors.ErrorMismatchIntoto,
|
||||
|
||||
@@ -521,8 +521,8 @@ func Test_VerifyTextProvenance(t *testing.T) {
|
||||
}
|
||||
|
||||
if err = json.Unmarshal(patch, &prov.verifiedProvenance.Build.UnverifiedTextIntotoStatement); err != nil {
|
||||
// If we updated a characters that make a non-string fiel invalid, like Time, unmarshalin will fail,
|
||||
// and we ignore the error.
|
||||
// If we updated a character that makes a non-string field invalid, like Time, unmarshaling will fail,
|
||||
// so we ignore the error.
|
||||
i += 1
|
||||
patch = []byte(strings.Clone(string(cpy)))
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user