Expose NewWriter from internal for openshift-tests-extension#16
Conversation
bertinatto
left a comment
There was a problem hiding this comment.
/lgtm
I don't see a problem with exposing a new constructor, as this won't affect existing code not using it and it can be useful to write to anything other than stdout.
|
@bertinatto: changing LGTM is restricted to collaborators DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Ginkgo's output writer hardcodes output to always go to os.Stdout, this exposes the NewWriter function so openshift-tests-extension can use it. This gives us more control over how we handle output from ginkgo, including writing it to `stderr` instead of `stdout`, or writing it to `io.Discard`, while maintaing the bytes buffer for returning output to OTE.
|
[APPROVALNOTIFIER] This PR is APPROVED Approval requirements bypassed by manually added approval. This pull-request has been approved by: bertinatto, stbenjam The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Expose NewWriter from internal for openshift-tests-extension
Update suite.config.Timeout configuration logic for ginkgo v2.4 bump Make sure ginkgo.By is printed Merge pull request openshift#15 from stbenjam/labels Patch spec to allow access to labels for tests Merge pull request openshift#16 from stbenjam/writer Expose NewWriter from internal for openshift-tests-extension Remove bparees and soltysh from owners
Update suite.config.Timeout configuration logic for ginkgo v2.4 bump Make sure ginkgo.By is printed Merge pull request #15 from stbenjam/labels Patch spec to allow access to labels for tests Merge pull request #16 from stbenjam/writer Expose NewWriter from internal for openshift-tests-extension Remove bparees and soltysh from owners
Update suite.config.Timeout configuration logic for ginkgo v2.4 bump Make sure ginkgo.By is printed Merge pull request #15 from stbenjam/labels Patch spec to allow access to labels for tests Merge pull request #16 from stbenjam/writer Expose NewWriter from internal for openshift-tests-extension Remove bparees and soltysh from owners
Update suite.config.Timeout configuration logic for ginkgo v2.4 bump Make sure ginkgo.By is printed Merge pull request openshift#15 from stbenjam/labels Patch spec to allow access to labels for tests Merge pull request openshift#16 from stbenjam/writer Expose NewWriter from internal for openshift-tests-extension Remove bparees and soltysh from owners
Update suite.config.Timeout configuration logic for ginkgo v2.4 bump Make sure ginkgo.By is printed Merge pull request openshift#15 from stbenjam/labels Patch spec to allow access to labels for tests Merge pull request openshift#16 from stbenjam/writer Expose NewWriter from internal for openshift-tests-extension Remove bparees and soltysh from owners
Ginkgo's output writer hardcodes output to always go to os.Stdout, this exposes the NewWriter function so openshift-tests-extension can use it.
This gives us more control over how we handle output from ginkgo, including writing it to
stderrinstead ofstdout, or writing it toio.Discard, while maintaing the bytes buffer for returning output to OTE.