Skip to content

upcoming: [UIE-9669] - Implement mocks and factories for Network LoadBalancer - #13104

Merged
harsh-akamai merged 5 commits into
linode:developfrom
harsh-akamai:uie-9669-add-mocks-to-nlb
Nov 19, 2025
Merged

upcoming: [UIE-9669] - Implement mocks and factories for Network LoadBalancer#13104
harsh-akamai merged 5 commits into
linode:developfrom
harsh-akamai:uie-9669-add-mocks-to-nlb

Conversation

@harsh-akamai

@harsh-akamai harsh-akamai commented Nov 18, 2025

Copy link
Copy Markdown
Contributor

Description 📝

Add mocks and factories for NLB

Note

Since Network LoadBalancer is only going to support GET API requests, I've added mocks to the legacy server handlers and not CRUD handlers

Scope 🚢

Upon production release, changes in this PR will be visible to:

  • All customers
  • Some customers (e.g. in Beta or Limited Availability)
  • No customers / Not applicable

How to test 🧪

Verification steps

  • Verify the mocks and factories return data in the same structure as APIs
Author Checklists

As an Author, to speed up the review process, I considered 🤔

👀 Doing a self review
❔ Our contribution guidelines
🤏 Splitting feature into small PRs
➕ Adding a changeset
🧪 Providing/improving test coverage
🔐 Removing all sensitive information from the code and PR description
🚩 Using a feature flag to protect the release
👣 Providing comprehensive reproduction steps
📑 Providing or updating our documentation
🕛 Scheduling a pair reviewing session
📱 Providing mobile support
♿ Providing accessibility support


  • I have read and considered all applicable items listed above.

As an Author, before moving this PR from Draft to Open, I confirmed ✅

  • All tests and CI checks are passing
  • TypeScript compilation succeeded without errors
  • Code passes all linting rules

@harsh-akamai
harsh-akamai marked this pull request as ready for review November 18, 2025 13:17
@harsh-akamai
harsh-akamai requested a review from a team as a code owner November 18, 2025 13:17
@harsh-akamai harsh-akamai self-assigned this Nov 18, 2025
@harsh-akamai harsh-akamai added the Network Load Balancers Related to Network Load Balancers label Nov 18, 2025
@linode-gh-bot

Copy link
Copy Markdown

Cloud Manager UI test results

🔺 1 failing test on test run #3 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
1 Failing861 Passing11 Skipped48m 48s

Details

Failing Tests
SpecTest
object-storage.e2e.spec.tsCloud Manager Cypress Tests→object storage end-to-end tests » can create and delete object storage buckets

Troubleshooting

Use this command to re-run the failing tests:

pnpm cy:run -s "cypress/e2e/core/objectStorage/object-storage.e2e.spec.ts"

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 mock server handlers and factory functions for the new Network LoadBalancer (NLB) feature, enabling local development and testing without requiring actual API calls.

Key Changes:

  • Added three factory functions for NetworkLoadBalancer, NetworkLoadBalancerListener, and NetworkLoadBalancerNode entities
  • Implemented five GET endpoint handlers for NLB resources in the mock server
  • Updated account factory to include 'Network LoadBalancer' capability

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/manager/src/factories/networkLoadBalancer.ts New file defining three factory functions for generating mock NLB data structures
packages/manager/src/factories/index.ts Export statement for new networkLoadBalancer factory module
packages/manager/src/mocks/serverHandlers.ts Five new mock handlers for NLB GET endpoints and integration into main handlers array
packages/manager/src/factories/account.ts Added 'Network LoadBalancer' to account capabilities list
packages/manager/.changeset/pr-13104-upcoming-features-1763472761959.md Changeset documenting the new feature

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@linode linode deleted a comment from Copilot AI Nov 19, 2025
@linode linode deleted a comment from Copilot AI Nov 19, 2025
@@ -0,0 +1,42 @@
import {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nit: This eslint error is still valid. Let's import type here.

@grevanak-akamai grevanak-akamai left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me

@github-project-automation github-project-automation Bot moved this from Review to Approved in Cloud Manager Nov 19, 2025
@harsh-akamai
harsh-akamai merged commit a69c687 into linode:develop Nov 19, 2025
34 of 35 checks passed
@github-project-automation github-project-automation Bot moved this from Approved to Merged in Cloud Manager Nov 19, 2025
@harsh-akamai
harsh-akamai deleted the uie-9669-add-mocks-to-nlb branch November 19, 2025 10:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Network Load Balancers Related to Network Load Balancers

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants