Skip to content

Commit 23bba25

Browse files
Fix type-o in test name. (#6086)
* Fix type-o in test name. I've also fixed a few other type-o's and spelling mistakes. Signed-off-by: David Lanouette <[email protected]> * Run go build -gcflags "all=-trimpath=/Users/dlanouet/code/opensource/operator-framework" -asmflags "all=-trimpath=/Users/dlanouet/code/opensource/operator-framework" -ldflags " -X 'github.com/operator-framework/operator-sdk/internal/version.Version=v1.24.0+git' -X 'github.com/operator-framework/operator-sdk/internal/version.GitVersion=v1.24.0-9-g2181a063-dirty' -X 'github.com/operator-framework/operator-sdk/internal/version.GitCommit=2181a063d750e4648b676950fcabe1a3baf3f8ae' -X 'github.com/operator-framework/operator-sdk/internal/version.KubernetesVersion=v1.25.0' -X 'github.com/operator-framework/operator-sdk/internal/version.ImageVersion=v1.24.0' " -o build ./cmd/{operator-sdk,ansible-operator,helm-operator} rm -rf testdata go run ./hack/generate/cncf-maintainers/main.go go run ./hack/generate/cli-doc/gen-cli-doc.go go run ./hack/generate/samples/generate_testdata.go running: docker rmi -f quay.io/example/memcached-operator:v0.0.1 warning: docker rmi -f quay.io/example/memcached-operator:v0.0.1 failed with error: (chdir /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/helm/memcached-operator: no such file or directory) cleaning up tools preparing testing directory: /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/helm/memcached-operator running: operator-sdk init --plugins helm --domain example.com --group cache --version v1alpha1 --kind Memcached --helm-chart ../../../hack/generate/samples/internal/helm/testdata/memcached-0.0.2.tgz running: make bundle IMG=quay.io/example/memcached-operator:v0.0.1 running: docker rmi -f quay.io/example/memcached-operator:v0.0.1 warning: docker rmi -f quay.io/example/memcached-operator:v0.0.1 failed with error: (chdir /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/ansible/memcached-operator: no such file or directory) cleaning up tools preparing testing directory: /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/ansible/memcached-operator running: operator-sdk init --plugins ansible --group cache --version v1alpha1 --kind Memcached --domain example.com --generate-role --generate-playbook running: make bundle IMG=quay.io/example/memcached-operator:v0.0.1 running: docker rmi -f quay.io/example/memcached-operator:v0.0.1 warning: docker rmi -f quay.io/example/memcached-operator:v0.0.1 failed with error: (chdir /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/go/v3/memcached-operator: no such file or directory) cleaning up tools preparing testing directory: /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/go/v3/memcached-operator running: operator-sdk init --plugins go/v3 --project-version 3 --repo github.com/example/memcached-operator --domain example.com running: operator-sdk create api --group cache --version v1alpha1 --kind Memcached --plugins deploy-image/v1-alpha --image memcached:1.4.36-alpine --image-container-command memcached,-m=64,-o,modern,-v --image-container-port 11211 --run-as-user 1001 --make=false --manifests=false running: operator-sdk create webhook --group cache --version v1alpha1 --kind Memcached --defaulting --defaulting running: go mod tidy running: make bundle IMG=quay.io/example/memcached-operator:v0.0.1 running: make fmt running: docker rmi -f quay.io/example/memcached-operator:v0.0.1 warning: docker rmi -f quay.io/example/memcached-operator:v0.0.1 failed with error: (chdir /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/go/v4-alpha/memcached-operator: no such file or directory) cleaning up tools preparing testing directory: /Users/dlanouet/code/opensource/operator-framework/operator-sdk/testdata/go/v4-alpha/memcached-operator running: operator-sdk init --plugins go/v3 --project-version 3 --repo github.com/example/memcached-operator --domain example.com running: operator-sdk create api --group cache --version v1alpha1 --kind Memcached --plugins deploy-image/v1-alpha --image memcached:1.4.36-alpine --image-container-command memcached,-m=64,-o,modern,-v --image-container-port 11211 --run-as-user 1001 --make=false --manifests=false running: operator-sdk create webhook --group cache --version v1alpha1 --kind Memcached --defaulting --defaulting running: go mod tidy running: make bundle IMG=quay.io/example/memcached-operator:v0.0.1 running: make fmt go generate ./... to update test data Signed-off-by: David Lanouette <[email protected]> Signed-off-by: David Lanouette <[email protected]>
1 parent a53cd4d commit 23bba25

File tree

5 files changed

+19
-19
lines changed

5 files changed

+19
-19
lines changed

hack/generate/samples/internal/go/memcached-with-webhooks/e2e_test_code.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ import (
1414
func (mh *Memcached) implementingE2ETests() {
1515
log.Infof("implementing example e2e tests")
1616

17-
// testdDir is testdata/go/v3/memcached-operator/test
17+
// testDir is testdata/go/v3/memcached-operator/test
1818
testDir := filepath.Join(mh.ctx.Dir, "test")
1919
// testE2eDir is testdata/go/v3/memcached-operator/test/e2e
2020
testE2eDir := filepath.Join(testDir, "e2e")
21-
// testE2eDir is testdata/go/v3/memcached-operator/test/utils
21+
// testUtilsDir is testdata/go/v3/memcached-operator/test/utils
2222
testUtilsDir := filepath.Join(testDir, "utils")
2323

2424
// Following we will create the directories
@@ -29,10 +29,10 @@ func (mh *Memcached) implementingE2ETests() {
2929
mh.addContent(testE2eDir, testUtilsDir)
3030

3131
// Add a target to run the tests into the Makefile
32-
mh.addTestE2eMaekefileTarget()
32+
mh.addTestE2eMakefileTarget()
3333
}
3434

35-
func (mh *Memcached) addTestE2eMaekefileTarget() {
35+
func (mh *Memcached) addTestE2eMakefileTarget() {
3636
err := kbutil.ReplaceInFile(filepath.Join(mh.ctx.Dir, "Makefile"),
3737
`KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test ./... -coverprofile cover.out`,
3838
`KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) -p path)" go test $(go list ./... | grep -v /test/) -coverprofile cover.out`,
@@ -176,17 +176,17 @@ var _ = Describe("memcached", func() {
176176
Expect(utils.InstallCertManager()).To(Succeed())
177177
178178
// The namespace can be created when we run make install
179-
// However, in this test we want ensure that the solution
179+
// However, in this test we want to ensure that the solution
180180
// can run in a ns labeled as restricted. Therefore, we are
181-
// creating the namespace an lebeling it.
181+
// creating the namespace and labeling it.
182182
By("creating manager namespace")
183183
cmd := exec.Command("kubectl", "create", "ns", namespace)
184184
_, _ = utils.Run(cmd)
185185
186-
// Now, let's ensure that all namespaces can raise an Warn when we apply the manifests
186+
// Now, let's ensure that all namespaces can raise a Warn when we apply the manifests
187187
// and that the namespace where the Operator and Operand will run are enforced as
188188
// restricted so that we can ensure that both can be admitted and run with the enforcement
189-
By("labeling all namespaces to warn when we apply the manifest if would violate the PodStandards")
189+
By("labeling all namespaces to warn when we apply the manifest if it would violate the PodStandards")
190190
cmd = exec.Command("kubectl", "label", "--overwrite", "ns", "--all",
191191
"pod-security.kubernetes.io/audit=restricted",
192192
"pod-security.kubernetes.io/enforce-version=v1.24",
@@ -376,7 +376,7 @@ func Run(cmd *exec.Cmd) ([]byte, error) {
376376
fmt.Fprintf(GinkgoWriter, "running dir: %s\n", cmd.Dir)
377377
378378
// To allow make commands be executed from the project directory which is subdir on SDK repo
379-
// TODO:(user) You might does not need the following code
379+
// TODO:(user) You might not need the following code
380380
if err := os.Chdir(cmd.Dir); err != nil {
381381
fmt.Fprintf(GinkgoWriter, "chdir dir: %s\n", err)
382382
}

testdata/go/v3/memcached-operator/test/e2e/e2e_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,17 +51,17 @@ var _ = Describe("memcached", func() {
5151
Expect(utils.InstallCertManager()).To(Succeed())
5252

5353
// The namespace can be created when we run make install
54-
// However, in this test we want ensure that the solution
54+
// However, in this test we want to ensure that the solution
5555
// can run in a ns labeled as restricted. Therefore, we are
56-
// creating the namespace an lebeling it.
56+
// creating the namespace and labeling it.
5757
By("creating manager namespace")
5858
cmd := exec.Command("kubectl", "create", "ns", namespace)
5959
_, _ = utils.Run(cmd)
6060

61-
// Now, let's ensure that all namespaces can raise an Warn when we apply the manifests
61+
// Now, let's ensure that all namespaces can raise a Warn when we apply the manifests
6262
// and that the namespace where the Operator and Operand will run are enforced as
6363
// restricted so that we can ensure that both can be admitted and run with the enforcement
64-
By("labeling all namespaces to warn when we apply the manifest if would violate the PodStandards")
64+
By("labeling all namespaces to warn when we apply the manifest if it would violate the PodStandards")
6565
cmd = exec.Command("kubectl", "label", "--overwrite", "ns", "--all",
6666
"pod-security.kubernetes.io/audit=restricted",
6767
"pod-security.kubernetes.io/enforce-version=v1.24",

testdata/go/v3/memcached-operator/test/utils/utils.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ func Run(cmd *exec.Cmd) ([]byte, error) {
5353
fmt.Fprintf(GinkgoWriter, "running dir: %s\n", cmd.Dir)
5454

5555
// To allow make commands be executed from the project directory which is subdir on SDK repo
56-
// TODO:(user) You might does not need the following code
56+
// TODO:(user) You might not need the following code
5757
if err := os.Chdir(cmd.Dir); err != nil {
5858
fmt.Fprintf(GinkgoWriter, "chdir dir: %s\n", err)
5959
}

testdata/go/v4-alpha/memcached-operator/test/e2e/e2e_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,17 +51,17 @@ var _ = Describe("memcached", func() {
5151
Expect(utils.InstallCertManager()).To(Succeed())
5252

5353
// The namespace can be created when we run make install
54-
// However, in this test we want ensure that the solution
54+
// However, in this test we want to ensure that the solution
5555
// can run in a ns labeled as restricted. Therefore, we are
56-
// creating the namespace an lebeling it.
56+
// creating the namespace and labeling it.
5757
By("creating manager namespace")
5858
cmd := exec.Command("kubectl", "create", "ns", namespace)
5959
_, _ = utils.Run(cmd)
6060

61-
// Now, let's ensure that all namespaces can raise an Warn when we apply the manifests
61+
// Now, let's ensure that all namespaces can raise a Warn when we apply the manifests
6262
// and that the namespace where the Operator and Operand will run are enforced as
6363
// restricted so that we can ensure that both can be admitted and run with the enforcement
64-
By("labeling all namespaces to warn when we apply the manifest if would violate the PodStandards")
64+
By("labeling all namespaces to warn when we apply the manifest if it would violate the PodStandards")
6565
cmd = exec.Command("kubectl", "label", "--overwrite", "ns", "--all",
6666
"pod-security.kubernetes.io/audit=restricted",
6767
"pod-security.kubernetes.io/enforce-version=v1.24",

testdata/go/v4-alpha/memcached-operator/test/utils/utils.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ func Run(cmd *exec.Cmd) ([]byte, error) {
5353
fmt.Fprintf(GinkgoWriter, "running dir: %s\n", cmd.Dir)
5454

5555
// To allow make commands be executed from the project directory which is subdir on SDK repo
56-
// TODO:(user) You might does not need the following code
56+
// TODO:(user) You might not need the following code
5757
if err := os.Chdir(cmd.Dir); err != nil {
5858
fmt.Fprintf(GinkgoWriter, "chdir dir: %s\n", err)
5959
}

0 commit comments

Comments
 (0)