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

chore: refactor cross namespace test to make it reusable #8157

Merged
merged 3 commits into from
Aug 22, 2024

Conversation

Cali0707
Copy link
Member

This refactors the cross namespace test to make the installation of the broker pluggable, enabling the test to be reused in EKB.

Proposed Changes

  • make the installation of the broker pluggable

@knative-prow knative-prow bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. area/test-and-release Test infrastructure, tests or release labels Aug 13, 2024
@Cali0707
Copy link
Member Author

/cc @creydr @Leo6Leo

@knative-prow knative-prow bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 13, 2024
@knative-prow knative-prow bot requested review from creydr and Leo6Leo August 13, 2024 18:50
Copy link

codecov bot commented Aug 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.46%. Comparing base (71d5d5f) to head (317a7b9).
Report is 11 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8157      +/-   ##
==========================================
- Coverage   67.71%   67.46%   -0.26%     
==========================================
  Files         370      371       +1     
  Lines       17946    18001      +55     
==========================================
- Hits        12152    12144       -8     
- Misses       5020     5085      +65     
+ Partials      774      772       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Cali0707
Copy link
Member Author

/cc @matzew

@knative-prow knative-prow bot requested a review from matzew August 14, 2024 18:36
@@ -50,5 +52,7 @@ func TestBrokerTriggerCrossNamespaceReference(t *testing.T) {
)

// brokerEnv.Test(brokerEnvCtx, t, broker.GoesReady(brokerName))
triggerEnv.Test(triggerEnvCtx, t, trigger.CrossNamespaceEventLinks(brokerEnvCtx))
triggerEnv.Test(triggerEnvCtx, t, trigger.CrossNamespaceEventLinks(brokerEnvCtx, func(name, namespace string) feature.StepFn {
return broker.Install(name, broker.WithNamespace(namespace))
Copy link
Member

Choose a reason for hiding this comment

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

Is there a reason you didn't reuse broker.GoesReady(name, brokerresources.WithEnvConfig()...)?

@knative-prow knative-prow bot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Aug 16, 2024
Copy link
Member

@pierDipi pierDipi left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@knative-prow knative-prow bot added the lgtm Indicates that a PR is ready to be merged. label Aug 22, 2024
Copy link

knative-prow bot commented Aug 22, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Cali0707, pierDipi

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 knative-prow bot merged commit 24a43e8 into knative:main Aug 22, 2024
34 of 36 checks passed
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 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.

3 participants