Skip to content

Commit

Permalink
Address fail forward unit test failures (#2747)
Browse files Browse the repository at this point in the history
The broken replacement chain unit test occasionally fails because it is
possible for either the a.v1 or a.v2 operators to cause the resolver to
fail. This commit updates the test to check that the resolver fails
because a csv is in the failed state versus checking that a specific
csv is in the failed state.

Signed-off-by: Alexander Greene <greene.al1991@gmail.com>
  • Loading branch information
awgreene committed Apr 18, 2022
1 parent 462ce61 commit c36183e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/controller/registry/resolver/step_resolver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1182,7 +1182,8 @@ func TestResolver(t *testing.T) {
steps: [][]*v1alpha1.Step{},
subs: []*v1alpha1.Subscription{},
errAssert: func(t *testing.T, err error) {
assert.Contains(t, err.Error(), "error using catalog @existing (in namespace catsrc-namespace): csv catsrc-namespace/a.v1 in phase Failed instead of Replacing")
assert.Contains(t, err.Error(), "error using catalog @existing (in namespace catsrc-namespace): csv")
assert.Contains(t, err.Error(), "in phase Failed instead of Replacing")
},
},
},
Expand Down

0 comments on commit c36183e

Please sign in to comment.