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

[BUG] e2e failed #348

Open
andyli029 opened this issue Dec 29, 2021 · 4 comments
Open

[BUG] e2e failed #348

andyli029 opened this issue Dec 29, 2021 · 4 comments
Labels
bug Something isn't working

Comments

@andyli029
Copy link
Contributor

Describe the problem

$ make e2e-local
=== RUN   TestE2E
STEP: Creating framework with timeout: 1200
Running Suite: MySQL Operator E2E Suite
=======================================
Random Seed: 1640748419 - Will randomize all specs
Will run 1 of 1 specs

STEP: Install operator
Error: rendered manifests contain a resource that already exists. Unable to continue with install: ClusterRole "mysql-operator-metrics-reader" in namespace "" exists and cannot be imported into the current release: invalid ownership metadata; annotation validation error: key "meta.helm.sh/release-name" must equal "yeshqc": current value is "demo"
Failure [0.972 seconds]
[BeforeSuite] BeforeSuite
/root/go/src/github.com/radondb/radondb-mysql-kubernetes/test/e2e/e2e.go:49

  Expected success, but got an error:
      <*exec.ExitError | 0xc0003a8000>: {
....
  /root/go/src/github.com/radondb/radondb-mysql-kubernetes/test/e2e/framework/helm.go:40
------------------------------
STEP: Remove operator release
Error: uninstall: Release not loaded: yeshqc: release: not found

Failure [0.000 seconds]
[AfterSuite] AfterSuite
/root/go/src/github.com/radondb/radondb-mysql-kubernetes/test/e2e/e2e.go:83

  Expected success, but got an error:
      <*exec.ExitError | 0xc000568040>: {
....
  /root/go/src/github.com/radondb/radondb-mysql-kubernetes/test/e2e/framework/helm.go:53
------------------------------

Ran 1 of 0 Specs in 1.043 seconds
FAIL! -- 0 Passed | 1 Failed | 0 Pending | 0 Skipped

To Reproduce

Expected behavior

Environment:

@andyli029 andyli029 added the bug Something isn't working label Dec 29, 2021
@andyli029
Copy link
Contributor Author

andyli029 commented Dec 29, 2021

Fix the case:

$ helm ls --all --all-namespaces | grep mysql-operator

NAME                         	NAMESPACE                   	REVISION	UPDATED                                	STATUS         	CHART                      	APP VERSION
demo                         	mysql-operator              	1       	2021-12-28 03:24:11.657721954 +0000 UTC	uninstalling   	mysql-operator-0.1.1       	latest

$ helm delete demo -n mysql-operator
$ make e2e-local
Ran 1 of 1 Specs in 21.534 seconds
SUCCESS! -- 1 Passed | 0 Failed | 0 Pending | 0 Skipped

@andyli029
Copy link
Contributor Author

Link: #302

@runkecheng
Copy link
Collaborator

If the framework is allowed to automatically delete existing resources, the original resources may not be able to run after the test runs.

@acekingke
Copy link
Contributor

I have suggest the release name should be random.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants