Skip to content

refactor: [M3-9614] - Move getUserTimeZone and its associated profile factories - #11955

Merged
pmakode-akamai merged 10 commits into
linode:developfrom
pmakode-akamai:M3-9614-move-getUserTimeZone-and-associated-profile-factories
Apr 7, 2025
Merged

pmakode-akamai merged 10 commits into
linode:developfrom
pmakode-akamai:M3-9614-move-getUserTimeZone-and-associated-profile-factories

Conversation

@pmakode-akamai

Copy link
Copy Markdown
Contributor

Description 📝

Move getUserTimeZone and its associated profile factories

Changes 🔄

  • Move getUserTimeZone and associated profile factories from manager to utilities package

Target release date 🗓️

N/A

How to test 🧪

  • Confirm all checks pass
  • Ensure all unit tests pass in @linode/utilities
  • Confirm all the necessary imports are updated
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 unit tests are passing
  • TypeScript compilation succeeded without errors
  • Code passes all linting rules

@pmakode-akamai
pmakode-akamai marked this pull request as ready for review April 2, 2025 12:18
@pmakode-akamai
pmakode-akamai requested review from a team as code owners April 2, 2025 12:18
@pmakode-akamai
pmakode-akamai requested review from bill-akamai, dwiley-akamai and jdamore-linode and removed request for a team April 2, 2025 12:18

@bill-akamai bill-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.

Great job @pmakode-akamai - that was lot of files to update.
I do see failing tests though:

src/utilities/formatDate.test.ts

Test: "formatDate utility > Non-humanized dates > should be displayed in 24-hour ISO format"


src/components/DateTimeDisplay/DateTimeDisplay.test.tsx

Test: "DateTimeDisplay component > should not display the time"
Test: "DateTimeDisplay component > should display the time"
Test: "DateTimeDisplay component > should format the time based on the specified format only"
Test: "DateTimeDisplay component > should format the time based on the specified format only pt2"
Test: "DateTimeDisplay component > Non-humanized dates > should be displayed in 24-hour ISO format"


src/features/Databases/DatabaseLanding/DatabaseLanding.test.tsx

Test: "Database Table > should render database landing with empty state"
Test: "Database Table > should render logo in new databases tab"


src/features/Billing/BillingPanels/BillingActivityPanel/BillingActivityPanel.test.tsx

Test: "BillingActivityPanel > should display 'Account active since'"

@github-project-automation github-project-automation Bot moved this from Review to Changes Requested in Cloud Manager Apr 2, 2025
@pmakode-akamai

Copy link
Copy Markdown
Contributor Author

Good catch, @bill-akamai! I’m not sure why there aren't any failures in CI, but I did notice test failures locally because I missed updating the mocks.

Should be all set now ✅

@bill-akamai

Copy link
Copy Markdown
Contributor

Good catch, @bill-akamai! I’m not sure why there aren't any failures in CI, but I did notice test failures locally because I missed updating the mocks.

Should be all set now ✅

Thanks @pmakode-akamai - I pulled the latest but am seeing 3 test failures still:

src/features/Linodes/LinodeEntityDetail.test.tsx
Test: "Linode Entity Detail > should display the VPC section if the linode is assigned to a VPC"


src/features/Databases/DatabaseLanding/DatabaseLanding.test.tsx
Test: "Database Table > should render logo in new databases tab"


src/features/Images/ImagesLanding/ImageRow.test.tsx
Test: "Image Table Row > calls handlers when performing actions"

@pmakode-akamai

Copy link
Copy Markdown
Contributor Author

Thanks @pmakode-akamai - I pulled the latest but am seeing 3 test failures still

@bill-akamai I wasn't able to reproduce those test failures locally, and it seems unrelated to the changes made in the PR. I re-ran all the tests on my end, and they all passed successfully.
Screenshot 2025-04-03 at 2 41 27 AM

Could you try running pnpm bootstrap && pnpm test again?

@bill-akamai

Copy link
Copy Markdown
Contributor

Could you try running pnpm bootstrap && pnpm test again?

That was successful. I thought I had done so before but everything is passing now - good to go! 👍

@pmakode-akamai pmakode-akamai added the Add'tl Approval Needed Waiting on another approval! label Apr 3, 2025

@dwiley-akamai dwiley-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.

Checks pass ✅
@linode/utilities unit tests pass ✅
Imports updated ✅

@github-project-automation github-project-automation Bot moved this from Changes Requested to Approved in Cloud Manager Apr 4, 2025
@pmakode-akamai pmakode-akamai added Approved Multiple approvals and ready to merge! and removed Add'tl Approval Needed Waiting on another approval! labels Apr 7, 2025
@linode-gh-bot

Copy link
Copy Markdown

Cloud Manager UI test results

🎉 540 passing tests on test run #11 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
0 Failing540 Passing4 Skipped101m 51s

@pmakode-akamai
pmakode-akamai merged commit 82c0046 into linode:develop Apr 7, 2025
@github-project-automation github-project-automation Bot moved this from Approved to Merged in Cloud Manager Apr 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Approved Multiple approvals and ready to merge! Modularization

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants