Skip to content

test: [UIE-10395 & UIE-10444] - Fix Parent/Child account switching bugs and test failures#13470

Merged
jdamore-linode merged 3 commits intolinode:developfrom
jdamore-linode:UIE-10444-account-switching-fixes
Mar 9, 2026
Merged

test: [UIE-10395 & UIE-10444] - Fix Parent/Child account switching bugs and test failures#13470
jdamore-linode merged 3 commits intolinode:developfrom
jdamore-linode:UIE-10444-account-switching-fixes

Conversation

@jdamore-linode
Copy link
Contributor

Description 📝

This is a quick PR to fix the Cypress test failures we're seeing with the Parent/Child account switching tests.

Changes 🔄

  • Fix a bug in the Parent/Child account switching drawer where Cloud Manager fails to fetch child accounts when signed in as a proxy user
  • Work around what I believe is a minor issue with our debounce search field component by adding a delay to Cypress's key strokes

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

Target release date 🗓️

Next release (3/18?)

How to test 🧪

Prerequisites

  • Confirm that tests pass
  • Confirm that when signed in as a proxy user, Cloud Manager fetches child accounts when (or prior to) opening the "Switch Accounts" drawer
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

: undefined,
},
isIAMDelegationEnabled === false && isParentUserType
isIAMDelegationEnabled === false && (isParentUserType || isProxyUserType)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This aims to fix two test failures in account-switching.spec.ts:

  • can switch from Proxy user back to Parent account user from Billing page
  • can switch to another Child account as a Proxy user

This relates to a change made by #13430. It doesn't look like we have a case to fetch child accounts when signed in as a proxy user and I believe this addition addresses that, but hoping for a quick sanity check cc @abailly-akamai @aaleksee-akamai

mockGetChildAccounts([]).as('getEmptySearchResults');
cy.findByPlaceholderText('Search').click();
cy.focused().type('Fake Name');
cy.focused().type('Fake Name', { delay: 50 });
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This test seems to be flaky because Cypress manages to type "Fake Name" into the debounced search field faster than 250ms, apparently causing the handleSearchQueryChange handler not to execute and preventing the search request from firing.

As best I can tell via git bisect, this began occurring after merging PR #13318 but I have not been able to identify the specific change that triggered the flakiness. I also looked into recent changes to <DebouncedSearchField /> made in #13292 and believe I've ruled that out as the cause as well.

I don't think this can actually be reproduced outside of automation so I'm happy to work around it from within the test, but just noting what I've looked into in case anybody would like to continue examining this.

@jdamore-linode jdamore-linode changed the title test: [UIE-10444] - Fix Parent/Child account switching bugs and test failures test: [UIE-10395 & UIE-10444] - Fix Parent/Child account switching bugs and test failures Mar 5, 2026
@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🔺 1 failing test on test run #2 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
1 Failing871 Passing11 Skipped39m 29s

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"

@jdamore-linode
Copy link
Contributor Author

^ The search test that I'm trying to fix failed twice before finally passing, so I'll have to take a second look at that

Copy link
Contributor

@abailly-akamai abailly-akamai left a comment

Choose a reason for hiding this comment

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

Thanks @jdamore-linode! Confirming this fixes the regression with the Switch Account Drawer for legacy Parent / Child accounts

Copy link
Contributor

@aaleksee-akamai aaleksee-akamai left a comment

Choose a reason for hiding this comment

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

Thanks a lot!

@github-project-automation github-project-automation bot moved this from Review to Approved in Cloud Manager Mar 9, 2026
@jdamore-linode jdamore-linode merged commit 9065bc6 into linode:develop Mar 9, 2026
34 of 35 checks passed
@github-project-automation github-project-automation bot moved this from Approved to Merged in Cloud Manager Mar 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Merged

Development

Successfully merging this pull request may close these issues.

4 participants