Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate nested reconcilers at test-time #583

Open
mamachanko opened this issue Jan 30, 2025 · 1 comment · May be fixed by #588
Open

Validate nested reconcilers at test-time #583

mamachanko opened this issue Jan 30, 2025 · 1 comment · May be fixed by #588
Assignees

Comments

@mamachanko
Copy link
Contributor

This is a follow-up for #578.

Given I have a nested reconciler (say Advice[Sequence[ChildReconciler, ChildReconciler]])
When I run tests for the outer reconciler (say Advice)
Then I would like my tests to error (not panic) and to see error messages for any of the reconcilers in the tree (say ChildReconciler)

@mamachanko
Copy link
Contributor Author

mamachanko commented Feb 3, 2025

@scothis would you be so kind and assign this to me? I can't self-assign.

mamachanko added a commit to mamachanko/reconcilerio-runtime that referenced this issue Feb 7, 2025
* Nested validation is configured via the context with
  reconcilers#WithNestedValidation

* (Sub)Reconciler tests always do nested validation

* Moves the Validator interface from testing into reconcilers

* Sequence now implements the Validator interface. Its Validate is not
  called from its SetupWithManager to avoid duplicate validations.

fixes reconcilerio#583

Signed-off-by: Max Brauer <[email protected]>
mamachanko added a commit to mamachanko/reconcilerio-runtime that referenced this issue Feb 7, 2025
* Nested validation is configured via the context with
  reconcilers#WithNestedValidation

* (Sub)Reconciler tests always do nested validation

* Moves the Validator interface from testing into reconcilers

* Sequence now implements the Validator interface. Its Validate is not
  called from its SetupWithManager to avoid duplicate validations.

fixes reconcilerio#583

Signed-off-by: Max Brauer <[email protected]>
@mamachanko mamachanko linked a pull request Feb 7, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant