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

Basic unit testing coverage for neonvm-controller #763

Open
2 of 4 tasks
sharnoff opened this issue Jan 25, 2024 · 1 comment
Open
2 of 4 tasks

Basic unit testing coverage for neonvm-controller #763

sharnoff opened this issue Jan 25, 2024 · 1 comment
Assignees
Labels
a/test Area: related to testing c/autoscaling/neonvm Component: autoscaling: NeonVM

Comments

@sharnoff
Copy link
Member

sharnoff commented Jan 25, 2024

Optional for neondatabase/company_projects#187.

Problem description / Motivation

The neonvm-controller's reconcile functions are huge and complex, with the majority of testing coming from system-wide end-to-end tests.

This leaves us over-exposed to uncommon scenarios or edge cases, along with little testing against degradations.

Feature idea(s) / DoD

More testing for the reconcile functions, mostly just to get it started. This is a continuing process

Implementation ideas

We may want to do something like what pkg/agent/core/state.go does, where the core of the logic is pure, and just returns the desired action to take.

While that would be a lot of work, maybe it's worth it to "force" all of the state to exist outside the control flow.

Also to look at how other k8s controllers are tested.

Related issues

Tasks

Preview Give feedback
@sharnoff sharnoff added a/test Area: related to testing c/autoscaling/neonvm Component: autoscaling: NeonVM labels Jan 25, 2024
@sharnoff sharnoff changed the title Unit testing coverage for neonvm-controller Basic unit testing coverage for neonvm-controller Feb 27, 2024
@Omrigan Omrigan self-assigned this Mar 4, 2024
@sharnoff
Copy link
Member Author

Status:

Omrigan added a commit that referenced this issue Jun 21, 2024
First PR, introducing unit tests. The old functional tests are moved to
a `functest` directory.

Part of #763

---------

Signed-off-by: Oleg Vasilev <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a/test Area: related to testing c/autoscaling/neonvm Component: autoscaling: NeonVM
Projects
None yet
Development

No branches or pull requests

2 participants