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

bump the name of the broker on each iter #4716

Merged
merged 1 commit into from
Jan 11, 2021

Conversation

vaikas
Copy link
Contributor

@vaikas vaikas commented Jan 11, 2021

Fixes ##4715

For example here:
https://github.com/knative/eventing/runs/1677836817?check_suite_focus=true

    broker_defaults_webhook_test.go:132: 
        	Error Trace:	broker_defaults_webhook_test.go:132
        	            				util.go:51
        	            				wait.go:211
        	            				wait.go:399
        	            				util.go:50
        	            				broker_defaults_webhook_test.go:112
        	Error:      	Expected nil, but got: &errors.StatusError{ErrStatus:v1.Status{TypeMeta:v1.TypeMeta{Kind:"Status", APIVersion:"v1"}, ListMeta:v1.ListMeta{SelfLink:"", ResourceVersion:"", Continue:"", RemainingItemCount:(*int64)(nil)}, Status:"Failure", Message:"brokers.eventing.knative.dev \"xyz-0\" already exists", Reason:"AlreadyExists", Details:(*v1.StatusDetails)(0xc0021758c0), Code:409}}

Proposed Changes

  • When re-trying to create a Broker the name must not be the same or it will fail on subsequent tries because the Broker already exists.

Release Note

- :bug: Fix bug #4715 

Docs

@google-cla google-cla bot added the cla: yes Indicates the PR's author has signed the CLA. label Jan 11, 2021
@knative-prow-robot knative-prow-robot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jan 11, 2021
@knative-prow-robot knative-prow-robot added the area/test-and-release Test infrastructure, tests or release label Jan 11, 2021
@slinkydeveloper
Copy link
Contributor

slinkydeveloper commented Jan 11, 2021

Makes sense to me, let's see if the test pass.

I think the reason why we see segfault more than properly failing with that error is that we use assert. at the line above, that doesn't fail the test immediately. Should it be replaced with require. instead?

@codecov
Copy link

codecov bot commented Jan 11, 2021

Codecov Report

Merging #4716 (6cbd082) into master (3783706) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #4716   +/-   ##
=======================================
  Coverage   81.07%   81.07%           
=======================================
  Files         291      291           
  Lines        8216     8216           
=======================================
  Hits         6661     6661           
  Misses       1154     1154           
  Partials      401      401           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3783706...6cbd082. Read the comment docs.

@pierDipi
Copy link
Member

n++ was deleted during a refactoring 996443c#diff-d5ffd7ccedaa63b719888c0fdffa388fc8527e396063f47c86d982d8403290d0L111

Makes sense to me, let's see if the test pass.

I think the reason why we see segfault more than properly failing with that error is that we use assert. at the line above, that doesn't fail the test immediately. Should it be replaced with require. instead?

#4717

@slinkydeveloper
Copy link
Contributor

/lgtm
/approve

@knative-prow-robot knative-prow-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 11, 2021
@knative-prow-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: slinkydeveloper, vaikas

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@knative-prow-robot knative-prow-robot merged commit 79344e8 into knative:master Jan 11, 2021
@vaikas vaikas deleted the default-broker-tests branch January 11, 2021 11:11
@xtreme-sameer-vohra
Copy link
Contributor

Makes sense to me, let's see if the test pass.

I think the reason why we see segfault more than properly failing with that error is that we use assert. at the line above, that doesn't fail the test immediately. Should it be replaced with require. instead?

Using a require rather than assert makes sense as the check is more for a test setup which should fail immediately rather than a result assertion (where there might be multiple assertions)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/test-and-release Test infrastructure, tests or release cla: yes Indicates the PR's author has signed the CLA. lgtm Indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants