Project: Operator Framework (App Definition and Development / Application Definition & Image Build)
File: qa-samples-proposal.md

title: QA Samples Proposal authors: "@camilamacedo86" reviewers: TBD approvers: TBD creation-date: 2019-11-22 last-updated: 2019-11-22 status: implementable \[x\] Enhancement is `implementable` \[x\] Design details are appropriately documented from clear requirements \[x\] Test plan is defined \[x\] Graduation criteria for dev preview, tech preview, GA \ The Operator SDK has a repo with [sample projects](https://github.com/operator-framework/operator-sdk-samples ). This proposal describes quality improvements in for the sample projects. Address issues raised in the repository such as ; , , , . Make easier the process to review changes made for the projects Help users know how they can achieve common good practices As a maintainer, I would like to ensure that samples projects continue to work after the changes performed in the PR are applied As an operator developer, I would like to know how to cover the projects with tests As an operator developer, I would like to know how to use the to do unit and integration tests As an operator developer, I would like to know how to call the tests in the CI and integrate them with Travis As an operator developer, I would like to know good practices to ensure the quality of my operators projects NOTE The above goals are valid for the 3 types/projects Go, Ansible and Helm Change the code business logic implementation of the projects Cover the projects with unit and integration tests. Integrate projects with Travis Integrate projects with Coveralls I as a GO operator developer, I would like to know how to cover the projects with unit tests using the test-framework Acceptance Criteria The GO project should have a minimum of 70% of its implementation covered by unit tests. The tests should all pass. The project should have a makefile target to call the tests A section with a short info over how to tests and the links for its documents in the README of the project The tests should be done using the default GO testing lib and the provided by SDK NOTES See an example of how to cover the controller. See an example of how to create the fake client. I as a Go dev operator user, I'd like to know how to cover the projects with integration tests using the test-framework Acceptance Criteria The GO project should be covered with a few basic integration tests The tests should all

The project should have a makefile target to call the integration test A section with a short info over how to tests and the links for its documents in the README of the project The tests should be done using the default GO testing lib and the provided by SDK As an Ansible operator developer, I would like to know how to cover the projects with unit tests using molecule Acceptance Criteria The Ansible project should be covered by tests using which by default is scaffold The tests should all pass. A section with a short info over how to tests and the links for its documents in the README of the project The project should have a makefile target to call the tests As an Helm operator developer, I would like to how to cover the projects with tests Acceptance Criteria The Helm project should have test shell scripts as seen .- The tests should all pass. A section with a short info over how to tests and the links for its documents in the README of the project The project should have a makefile target to call the tests As an Ansible operator developer, I'd like to how to cover the projects with integration tests using molecule Acceptance Criteria The Ansible project should have a few integration tests using which by default is scaffold The tests should all pass. A section with a short info over how to tests and the links for its documents in the README of the project The project should have a makefile target to call the tests As an operator-sdk maintainer, I would like ensure that samples continue to work after the changes performed in the PR are applied. As an operator developer, I would like to know how to call the tests in the CI and integrate them with Travis Acceptance Criteria The Ansible, Helm and Go project should be integrated with Travis All PRs against the master branch should trigger the CI The unit and integration tests should be checked in the CI The CI should fail if one of the tests do not pass As an operator developer, I'd like to know good practices to ensure the quality of my operators projects Acceptance Criteria Ansible and GO Memcached samples should be integrated with All above stories should be achieved successfully may not work well with , if this is the case we can just not integrate with it or we can find a similar tool.