Skip to content

Commit

Permalink
Adding installing steps for testing webhooks
Browse files Browse the repository at this point in the history
  • Loading branch information
Yash Singh committed Oct 6, 2022
1 parent a5abeb6 commit 79f659e
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions docs/book/src/reference/envtest.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,8 @@ var _ = AfterSuite(func() {
<aside class="note">
<h1>ENV TEST Config Options</h1>

You can look at the controller-runtime docs to know more about its configuration options, see [here](https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/envtest#Environment)
You can look at the controller-runtime docs to know more about its configuration options, see [here](https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/envtest#Environment). On top of that, if you are
looking to use ENV TEST to test your webhooks then you might want to give a look at its install [options](https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/envtest#WebhookInstallOptions).

</aside>

Expand Down Expand Up @@ -191,12 +192,7 @@ Following an example.

```go
BeforeEach(func() {
var err error
kbc, err = utils.NewTestContext(util.KubebuilderBinName, "GO111MODULE=on")
Expect(err).NotTo(HaveOccurred())
Expect(kbc.Prepare()).To(Succeed())
By("installing the cert-manager bundle")
By("installing the cert-manager bundle")
Expect(kbc.InstallCertManager(false)).To(Succeed())
By("installing the Prometheus operator")
Expand Down

0 comments on commit 79f659e

Please sign in to comment.