Skip to content

Implement UTs for WorkloadReconciler predicate functions #8501

@tenzen-y

Description

@tenzen-y

What would you like to be cleaned:

I'd propose implementing UTs for the WorkloadReconciler predicate functions (Create, Update, ...).

func (r *WorkloadReconciler) Create(e event.TypedCreateEvent[*kueue.Workload]) bool {

func (r *WorkloadReconciler) Delete(e event.TypedDeleteEvent[*kueue.Workload]) bool {

func (r *WorkloadReconciler) Update(e event.TypedUpdateEvent[*kueue.Workload]) bool {

func (r *WorkloadReconciler) Generic(e event.TypedGenericEvent[*kueue.Workload]) bool {

Why is this needed:

The WorkloadReconciler predicates are very complicated, but we have no UT. So, I believe that adding UTs stabilizes the workload controller.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/cleanupCategorizes issue or PR as related to cleaning up code, process, or technical debt.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions