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

Add e2e test for registering CassandraDatacenters #10

Closed
jsanda opened this issue Nov 20, 2020 · 2 comments · May be fixed by #16
Closed

Add e2e test for registering CassandraDatacenters #10

jsanda opened this issue Nov 20, 2020 · 2 comments · May be fixed by #16

Comments

@jsanda
Copy link
Contributor

jsanda commented Nov 20, 2020

We need an e2e test to exercise cassandradatacenter_controller.go. The test should minimally do the following:

  • Deploy a Reaper instance with a CassandraDatacenter backend
  • Register the CassandraDatacenter

It would be nice to also do the following (but not absolutely necessary):

  • Deploy and register a second CassandraDatacenter
  • Remove the CassandraDatacenter from Reaper via REST API and verify that the CassandraDatacenter is added back
@burmanm
Copy link
Contributor

burmanm commented Nov 23, 2020

Isn't deploy_reaper_test.go already doing the first two parts?

The integ test does the latter one's reregistering.

@jsanda
Copy link
Contributor Author

jsanda commented Nov 23, 2020

Isn't deploy_reaper_test.go already doing the first two parts?

Yeah, you are right.

Looking back over the e2e test code, the following might be better:

  • Deploy Reaper before Cassandra. deploy_reaper_test.go waits for the CassandraDatacenter to become ready before deploying Reaper
    • Verify Reaper reaches ready state
  • Deploy a second CassandraDatacenter that has the reaper annotation and that is not Reaper's backend
    • Verify the Cassandra cluster is registered with Reaper
  • Remove Cassandra cluster from Reaper
    • Verify the cluster gets added back

Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants