Skip to content

Conversation

@uaggarwa
Copy link

@uaggarwa uaggarwa commented Oct 20, 2025

📝 Description

What does this PR do and why is this change necessary?
linode-load-balancer-controller requires nlb-endpoints implemented by linodego. We want to move from our fork to main branch.

✔️ How to Test

What are the steps to reproduce the issue or verify the changes?

How do I run the relevant unit/integration tests?

go test ./test/unit -run TestNetLoadBalancer -v
go test ./test/unit -run TestNetLoadBalancerNode -v
go test ./test/unit -run TestNetLoadBalancerListener -v 

📷 Preview

If applicable, include a screenshot or code snippet of this change. Otherwise, please remove this section.

@uaggarwa uaggarwa requested a review from a team as a code owner October 20, 2025 19:09
@uaggarwa uaggarwa requested review from Copilot, vshanthe and zliang-akamai and removed request for a team October 20, 2025 19:09
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds comprehensive test coverage for NetLoadBalancer endpoints, including operations for load balancers, listeners, and nodes. The implementation includes unit tests for CRUD operations, JSON unmarshaling, edge cases, and conversion methods.

  • Adds unit tests for NetLoadBalancer, NetLoadBalancerListener, and NetLoadBalancerNode endpoints
  • Implements JSON fixtures to support the test cases
  • Includes tests for helper methods (GetCreateOptions, GetUpdateOptions)

Reviewed Changes

Copilot reviewed 30 out of 30 changed files in this pull request and generated no comments.

Show a summary per file
File Description
test/unit/netloadbalancer_test.go Tests for NetLoadBalancer CRUD operations, JSON unmarshaling, and conversion methods
test/unit/netloadbalancer_listeners_test.go Tests for listener CRUD operations, node weight updates, and edge cases
test/unit/netloadbalancer_nodes_test.go Tests for node CRUD operations, conversion methods, and edge cases
test/unit/fixtures/*.json JSON fixtures supporting various test scenarios for load balancers, listeners, and nodes
netloadbalancer.go Core NetLoadBalancer struct and API methods
netloadbalancer_listeners.go NetLoadBalancerListener struct and API methods
netloadbalancer_nodes.go NetLoadBalancerNode struct and API methods

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@uaggarwa uaggarwa changed the title Nlb endpoints tests [CNS-5114] Nlb endpoints tests Oct 20, 2025
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

Successfully merging this pull request may close these issues.

1 participant