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

test: Add Negative unit tests #596

Merged
merged 10 commits into from
Nov 14, 2023
Merged

Conversation

britaniar
Copy link
Contributor

Description of your changes

Add negative unit tests to TestReconcilerUpdateBindings function.

Fixes #

I have:

  • Run make reviewable to ensure this PR is ready for review.

How has this code been tested

Special notes for your reviewer

@britaniar britaniar marked this pull request as ready for review November 6, 2023 21:18
@Arvindthiru
Copy link
Contributor

Arvindthiru commented Nov 6, 2023

There are more negative UTs to be added, there are three branches where,

  • The first branch with case fleetv1beta1.BindingStateBound has an Update you can mock to return error
  • The second branch with case fleetv1beta1.BindingStateScheduled has another update you can mock to return error
  • The third branch with case fleetv1beta1.BindingStateUnscheduled has a Delete which can possibly return a not found error or some other error as well

Arvindthiru
Arvindthiru previously approved these changes Nov 8, 2023
Copy link
Contributor

@Arvindthiru Arvindthiru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!!

@britaniar britaniar merged commit 32e9f84 into Azure:main Nov 14, 2023
@britaniar britaniar deleted the rollout_negative_UTs branch November 14, 2023 17:25
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 this pull request may close these issues.

3 participants