-
Notifications
You must be signed in to change notification settings - Fork 422
CNTRLPLANE-2167:Integrate OpenShift Test Extension (OTE) into oc #2160
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
Open
gangwgr
wants to merge
2
commits into
openshift:main
Choose a base branch
from
gangwgr:test-module-infra-only
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,5 @@ | ||
| /oc | ||
| /oc-tests-ext | ||
| /clicheck | ||
| /gendocs | ||
| /gendocs-admin | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,53 @@ | ||
| package main | ||
|
|
||
| import ( | ||
| "context" | ||
| "os" | ||
|
|
||
| "github.com/spf13/cobra" | ||
| "k8s.io/component-base/cli" | ||
|
|
||
| otecmd "github.com/openshift-eng/openshift-tests-extension/pkg/cmd" | ||
| oteextension "github.com/openshift-eng/openshift-tests-extension/pkg/extension" | ||
| "github.com/openshift/oc/pkg/version" | ||
|
|
||
| "k8s.io/klog/v2" | ||
| ) | ||
|
|
||
| func main() { | ||
| command := newOperatorTestCommand(context.Background()) | ||
| code := cli.Run(command) | ||
| os.Exit(code) | ||
| } | ||
|
|
||
| func newOperatorTestCommand(ctx context.Context) *cobra.Command { | ||
| registry := prepareOperatorTestsRegistry() | ||
|
|
||
| cmd := &cobra.Command{ | ||
| Use: "oc-tests-ext", | ||
| Short: "A binary used to run oc tests as part of OTE.", | ||
| Run: func(cmd *cobra.Command, args []string) { | ||
| if err := cmd.Help(); err != nil { | ||
| klog.Fatal(err) | ||
| } | ||
| }, | ||
| } | ||
|
|
||
| if v := version.Get().String(); len(v) == 0 { | ||
| cmd.Version = "<unknown>" | ||
| } else { | ||
| cmd.Version = v | ||
| } | ||
|
|
||
| cmd.AddCommand(otecmd.DefaultExtensionCommands(registry)...) | ||
|
|
||
| return cmd | ||
| } | ||
|
|
||
| func prepareOperatorTestsRegistry() *oteextension.Registry { | ||
| registry := oteextension.NewRegistry() | ||
| extension := oteextension.NewExtension("openshift", "payload", "oc") | ||
|
|
||
| registry.Register(extension) | ||
| return registry | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| 7.3.2 | ||
| # Keep this pinned version in parity with cel-go |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| *.pb.go linguist-generated=true | ||
| *.pb.go -diff -merge |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| bazel-* | ||
| MODULE.bazel.lock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| load("@io_bazel_rules_go//go:def.bzl", "go_library") | ||
|
|
||
| package(default_visibility = ["//visibility:public"]) | ||
|
|
||
| licenses(["notice"]) # Apache 2.0 | ||
|
|
||
| go_library( | ||
| name = "expr", | ||
| srcs = [ | ||
| "checked.pb.go", | ||
| "eval.pb.go", | ||
| "explain.pb.go", | ||
| "syntax.pb.go", | ||
| "value.pb.go", | ||
| ], | ||
| importpath = "cel.dev/expr", | ||
| visibility = ["//visibility:public"], | ||
| deps = [ | ||
| "@org_golang_google_genproto_googleapis_rpc//status:go_default_library", | ||
| "@org_golang_google_protobuf//reflect/protoreflect", | ||
| "@org_golang_google_protobuf//runtime/protoimpl", | ||
| "@org_golang_google_protobuf//types/known/anypb", | ||
| "@org_golang_google_protobuf//types/known/durationpb", | ||
| "@org_golang_google_protobuf//types/known/emptypb", | ||
| "@org_golang_google_protobuf//types/known/structpb", | ||
| "@org_golang_google_protobuf//types/known/timestamppb", | ||
| ], | ||
| ) | ||
|
|
||
| alias( | ||
| name = "go_default_library", | ||
| actual = ":expr", | ||
| visibility = ["//visibility:public"], | ||
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| # Contributor Code of Conduct | ||
| ## Version 0.1.1 (adapted from 0.3b-angular) | ||
|
|
||
| As contributors and maintainers of the Common Expression Language | ||
| (CEL) project, we pledge to respect everyone who contributes by | ||
| posting issues, updating documentation, submitting pull requests, | ||
| providing feedback in comments, and any other activities. | ||
|
|
||
| Communication through any of CEL's channels (GitHub, Gitter, IRC, | ||
| mailing lists, Google+, Twitter, etc.) must be constructive and never | ||
| resort to personal attacks, trolling, public or private harassment, | ||
| insults, or other unprofessional conduct. | ||
|
|
||
| We promise to extend courtesy and respect to everyone involved in this | ||
| project regardless of gender, gender identity, sexual orientation, | ||
| disability, age, race, ethnicity, religion, or level of experience. We | ||
| expect anyone contributing to the project to do the same. | ||
|
|
||
| If any member of the community violates this code of conduct, the | ||
| maintainers of the CEL project may take action, removing issues, | ||
| comments, and PRs or blocking accounts as deemed appropriate. | ||
|
|
||
| If you are subject to or witness unacceptable behavior, or have any | ||
| other concerns, please email us at | ||
| [cel-conduct@google.com](mailto:cel-conduct@google.com). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| # How to Contribute | ||
|
|
||
| We'd love to accept your patches and contributions to this project. There are a | ||
| few guidelines you need to follow. | ||
|
|
||
| ## Contributor License Agreement | ||
|
|
||
| Contributions to this project must be accompanied by a Contributor License | ||
| Agreement. You (or your employer) retain the copyright to your contribution, | ||
| this simply gives us permission to use and redistribute your contributions as | ||
| part of the project. Head over to <https://cla.developers.google.com/> to see | ||
| your current agreements on file or to sign a new one. | ||
|
|
||
| You generally only need to submit a CLA once, so if you've already submitted one | ||
| (even if it was for a different project), you probably don't need to do it | ||
| again. | ||
|
|
||
| ## Code reviews | ||
|
|
||
| All submissions, including submissions by project members, require review. We | ||
| use GitHub pull requests for this purpose. Consult | ||
| [GitHub Help](https://help.github.com/articles/about-pull-requests/) for more | ||
| information on using pull requests. | ||
|
|
||
| ## What to expect from maintainers | ||
|
|
||
| Expect maintainers to respond to new issues or pull requests within a week. | ||
| For outstanding and ongoing issues and particularly for long-running | ||
| pull requests, expect the maintainers to review within a week of a | ||
| contributor asking for a new review. There is no commitment to resolution -- | ||
| merging or closing a pull request, or fixing or closing an issue -- because some | ||
| issues will require more discussion than others. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| # Project Governance | ||
|
|
||
| This document defines the governance process for the CEL language. CEL is | ||
| Google-developed, but openly governed. Major contributors to the CEL | ||
| specification and its corresponding implementations constitute the CEL | ||
| Language Council. New members may be added by a unanimous vote of the | ||
| Council. | ||
|
|
||
| The MAINTAINERS.md file lists the members of the CEL Language Council, and | ||
| unofficially indicates the "areas of expertise" of each member with respect | ||
| to the publicly available CEL repos. | ||
|
|
||
| ## Code Changes | ||
|
|
||
| Code changes must follow the standard pull request (PR) model documented in the | ||
| CONTRIBUTING.md for each CEL repo. All fixes and features must be reviewed by a | ||
| maintainer. The maintainer reserves the right to request that any feature | ||
| request (FR) or PR be reviewed by the language council. | ||
|
|
||
| ## Syntax and Semantic Changes | ||
|
|
||
| Syntactic and semantic changes must be reviewed by the CEL Language Council. | ||
| Maintainers may also request language council review at their discretion. | ||
|
|
||
| The review process is as follows: | ||
|
|
||
| - Create a Feature Request in the CEL-Spec repo. The feature description will | ||
| serve as an abstract for the detailed design document. | ||
| - Co-develop a design document with the Language Council. | ||
| - Once the proposer gives the design document approval, the document will be | ||
| linked to the FR in the CEL-Spec repo and opened for comments to members of | ||
| the cel-lang-discuss@googlegroups.com. | ||
| - The Language Council will review the design doc at the next council meeting | ||
| (once every three weeks) and the council decision included in the document. | ||
|
|
||
| If the proposal is approved, the spec will be updated by a maintainer (if | ||
| applicable) and a rationale will be included in the CEL-Spec wiki to ensure | ||
| future developers may follow CEL's growth and direction over time. | ||
|
|
||
| Approved proposals may be implemented by the proposer or by the maintainers as | ||
| the parties see fit. At the discretion of the maintainer, changes from the | ||
| approved design are permitted during implementation if they improve the user | ||
| experience and clarity of the feature. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Many people, CI systems rely on this
cliimage. This change increases the storage size which may have unexpected impacts.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ardaguclu We have same discussed with @p0lyn0mial here https://redhat-internal.slack.com/archives/CC3CZCQHM/p1762421042028719 regarding kas-o
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR integrates with https://docs.google.com/document/d/1cFZj9QdzW8hbHc3H0Nce-2xrJMtpDJrwAse9H7hLiWk/edit?tab=t.0#heading=h.66y4kqbj468a
TLDR: it’s about integrating tests from this repository with openshift-tests to improve coverage and protect against regressions.
BTW: do we actually have any e2e tests defined for this repository? If not, maybe this PR isn’t needed at the moment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@p0lyn0mial In qe repo we have, need to migrate those here
@zhouying7780 Please confirm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@p0lyn0mial as checked with @zhouying7780 We have cases here