Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ref: Migrate to isTeamPlan GQ field #3592

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

RulaKhaled
Copy link
Contributor

@RulaKhaled RulaKhaled commented Dec 18, 2024

Description

This PR aims to remove the isTeamPlan helper function in Gazebo in favor of the new GraphQL field for the same.

fyi we're gonna come back once available plans is refactored to pass down isTeamPlan instead of checking for plans enum for the selected plans, this is just a weird edge case.

Notable Changes

  • updated tests
  • removed helper
  • updated the plan

Screenshots

nothing visual changed

issue: #2998

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

@RulaKhaled RulaKhaled marked this pull request as ready for review December 18, 2024 21:46
@codecov-staging
Copy link

codecov-staging bot commented Dec 18, 2024

Bundle Report

Changes will increase total bundle size by 3.38kB (0.02%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
gazebo-staging-system-esm 6.05MB 1.86kB (0.03%) ⬆️
gazebo-staging-system 6.0MB 1.52kB (0.03%) ⬆️

@codecov-notifications
Copy link

codecov-notifications bot commented Dec 18, 2024

❌ 14 Tests Failed:

Tests completed Failed Passed Skipped
4167 14 4153 0
View the top 3 failed tests by shortest run time
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > renders AccountOrgs
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /AccountOrgs/. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:426:40
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when shouldRenderBillingDetails should be shown > when usesInvoice is true > renders BillingDetails
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /BillingDetails/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:325:45
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > and less than 90% of seats are in use > does not render a usage banner
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /CurrentPlanCard/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:387:46

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

@codecov-qa
Copy link

codecov-qa bot commented Dec 18, 2024

❌ 14 Tests Failed:

Tests completed Failed Passed Skipped
4167 14 4153 0
View the top 3 failed tests by shortest run time
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > renders AccountOrgs
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /AccountOrgs/. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:426:40
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when shouldRenderBillingDetails should be shown > when usesInvoice is true > renders BillingDetails
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /BillingDetails/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:325:45
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > and less than 90% of seats are in use > does not render a usage banner
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /CurrentPlanCard/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:387:46

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

Copy link

codecov-public-qa bot commented Dec 18, 2024

❌ 14 Tests Failed:

Tests completed Failed Passed Skipped
4167 14 4153 0
View the top 3 failed tests by shortest run time
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > renders AccountOrgs
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /AccountOrgs/. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:426:40
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when shouldRenderBillingDetails should be shown > when usesInvoice is true > renders BillingDetails
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /BillingDetails/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:325:45
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > and less than 90% of seats are in use > does not render a usage banner
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /CurrentPlanCard/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:387:46

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

@codecov-releaser
Copy link
Contributor

codecov-releaser commented Dec 18, 2024

✅ Deploy preview for gazebo ready!

Previews expire after 1 month automatically.

Storybook

Commit Created Cloud Enterprise
dca781e Wed, 18 Dec 2024 21:52:53 GMT Expired Expired
6ddc688 Thu, 19 Dec 2024 19:57:05 GMT Expired Expired
8e7a1a4 Thu, 19 Dec 2024 22:20:56 GMT Cloud Enterprise

Copy link

codecov bot commented Dec 18, 2024

❌ 14 Tests Failed:

Tests completed Failed Passed Skipped
4167 14 4153 0
View the top 3 failed tests by shortest run time
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > renders AccountOrgs
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /AccountOrgs/. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:426:40
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when shouldRenderBillingDetails should be shown > when usesInvoice is true > renders BillingDetails
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /BillingDetails/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:325:45
src/pages/PlanPage/subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx > CurrentOrgPlan > when owner has an account > and less than 90% of seats are in use > does not render a usage banner
Stack Traces | 1s run time
TestingLibraryElementError: Unable to find an element with the text: /CurrentPlanCard/i. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>

Ignored nodes: comments, script, style
<body>
  <div>
    <div
      class="w-full lg:w-4/5"
    />
  </div>
</body>waitForWrapper node_modules/@.../dom/dist/wait-for.js:163:27node_modules/@.../dom/dist/query-helpers.js:86:33
 ❯ .../subRoutes/CurrentOrgPlan/CurrentOrgPlan.test.tsx:387:46

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

Copy link

codecov bot commented Dec 18, 2024

Bundle Report

Changes will increase total bundle size by 3.38kB (0.02%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
gazebo-production-system 6.0MB 1.52kB (0.03%) ⬆️
gazebo-production-system-esm 6.05MB 1.86kB (0.03%) ⬆️

@@ -48,7 +49,7 @@ const UpdateBlurb = ({
{diffSeats && (
<li className="pl-2">{`You are changing seats from ${currentPlan?.planUserCount} to [${seats}]`}</li>
)}
{diffBillingType && (
{diffBillingType && !currentIsFree && (
Copy link
Contributor

Choose a reason for hiding this comment

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

weird this is showing up, I thought I had committed it already

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.

3 participants