-
Notifications
You must be signed in to change notification settings - Fork 246
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 data access code against a live database #1811
Comments
Hey, @krancour I would like to contribute to this issue since GSOC is approaching and the CNCF is one of the orgs I want to apply for. Can you please help me get started so that I can get familiar with the codebase and other things about the project |
@meetguogengli please find me on the Kubernetes slack if you've got specific questions. |
Hi @krancour, I just added you on slack. Can you see my message? |
This has not been selected as a GSOC project, so I am going to decompose this epic-sized issue into much smaller ones and then close this one. |
Brigade is composed of many components. Among them, the API server could be considered the platform's brain and central nervous system. The API implements a clean abstraction over underlying services such as our database (MongoDB), our messaging system (Artemis), and our workload execution substrate (Kubernetes). All other Brigade components accomplish most of their work through API calls.
Where integration with the database is concerned, API server code is currently unit-tested against mock implementations of MongoDB client interfaces. These tests have been adequate for asserting that queries and statements are constructed properly (look like we think they should) and that mock query and statement results can be unmarshaled without error into domain types, but this approach cannot assert that DB queries and statement are logically correct and actually achieve the desired results, since a live database would be required to accomplish that. We do also have a suite of integration tests that run against a live instance of Brigade (database and all), but they are closer to end-to-end tests, so they do not isolate data access code. They may detect issues from time to time, but they're a poor way of pinpointing the root cause.
Given the importance of the data access code, we would like to develop a new suite of integration tests directly targeted at that code. These new tests should run against a live (and disposable) MongoDB database and assert that all queries and statements achieve the desired results. If the new suite of tests exposes bugs in the existing data access code, correcting those bugs is within the scope of this project as well.
No significant prior knowledge of Brigade or its codebase is required to work on this issue since the work is highly localized to a few discrete packages. The successful candidate will have strong Go and git skills and at least a working knowledge of Docker, since containers are likely the easiest way to quickly stand up and tear down a disposable test database. Prior knowledge of MongoDB would be an asset, but it is entirely possible that a successful candidate will be able to learn MongoDB as they go.
The expected outcome of this GSoC project is the new test suite merged into Brigade's main branch and fully integrated into our CI/CD processes.
This is estimated to be a low difficulty project that a qualified candidate can complete with roughly 175 hours of effort.
The text was updated successfully, but these errors were encountered: