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

Test improvement proposal #51

Closed
3 of 4 tasks
eversC opened this issue Jun 6, 2019 · 4 comments
Closed
3 of 4 tasks

Test improvement proposal #51

eversC opened this issue Jun 6, 2019 · 4 comments
Assignees

Comments

@eversC
Copy link
Collaborator

eversC commented Jun 6, 2019

  • mock call to ovotech/cloud-key-client

  • local key writer

  • Unit tests public Rotate() func

  • Add e2e tests for all key writers with real resources

@eversC eversC changed the title Test plans Test improvement proposal Jun 6, 2019
@siwally
Copy link
Contributor

siwally commented Jun 13, 2019

Current thoughts are that it's not worth introducing Testify or a similar mocking framework, given we only have a handful of functions to swap in.

Might just mock the function in cases where we don't have an interface, in which case the function can be called anything as long as the signature is the same. See https://stackoverflow.com/questions/19167970/mock-functions-in-go (option 1). Would just roll our own function then to return the test data, rather than use a framework.

@siwally
Copy link
Contributor

siwally commented Jun 13, 2019

Attempting to use cloud-key-client instead of mocking it, but to plug in a new local (i.e. mock) provider type in addition to AWS and GCP. Working in a separate branch (pluggable-providers) on cloud-key-client also.

@eversC
Copy link
Collaborator Author

eversC commented Oct 18, 2019

Closing this one off as unit tests have been added.

e2e tests are a good idea, will raise another issue for that.

@eversC eversC closed this as completed Oct 18, 2019
@eversC
Copy link
Collaborator Author

eversC commented Oct 18, 2019

In fact, one already exists.... #34

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants