cal.com icon indicating copy to clipboard operation
cal.com copied to clipboard

test: Create unit tests for react components in packages/ui/components/form/TimezoneSelect

Open gitstart-calcom opened this issue 1 year ago • 11 comments

command to run these tests: yarn test timezone

image

obs: the props that are passed to the component, have a specific and unique effect in the CSS, so the assertions are made with the hasClass

gitstart-calcom avatar Aug 15 '23 03:08 gitstart-calcom

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
ai ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 26, 2024 9:52pm
api ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 26, 2024 9:52pm
dev ❌ Failed (Inspect) Jan 26, 2024 9:52pm
5 Ignored Deployments
Name Status Preview Comments Updated (UTC)
cal ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2024 9:52pm
cal-demo ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2024 9:52pm
calcom-web-canary ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2024 9:52pm
qa ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2024 9:52pm
ui ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2024 9:52pm

vercel[bot] avatar Aug 15 '23 03:08 vercel[bot]

Thank you for following the naming conventions! 🙏 Feel free to join our discord and post your PR link.

github-actions[bot] avatar Aug 15 '23 03:08 github-actions[bot]

📦 Next.js Bundle Analysis for @calcom/web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

github-actions[bot] avatar Aug 15 '23 03:08 github-actions[bot]

Current Playwright Test Results Summary

✅ 90 Passing - ⚠️ 1 Flaky

Run may still be in progress, this comment will be updated as current testing workflow or job completes...

(Last updated on 01/27/2024 10:56:55am UTC)

Run Details

Running Workflow PR Update on Github Actions

Commit: 28e5640e1821e1dd5f0769e12a26aafab7d08fe3

Started: 01/27/2024 10:53:01am UTC

⚠️ Flakes

📄   apps/web/playwright/booking/availability.e2e.ts • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Check availability tab in a event-type Check availability in event type
Retry 1Initial Attempt
20.32% (51) 51 / 251 runs
failed over last 7 days
41.43% (104) 104 / 251 runs
flaked over last 7 days

View Detailed Build Results


deploysentinel[bot] avatar Aug 15 '23 03:08 deploysentinel[bot]

🤖 Meticulous spotted visual differences in 51 of 209 screens tested: view and approve differences detected.

Last updated for commit 9197d79. This comment will update as new commits are pushed.

alwaysmeticulous[bot] avatar Aug 15 '23 03:08 alwaysmeticulous[bot]

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Aug 28 '23 09:08 CLAassistant

This PR is being marked as stale due to inactivity.

github-actions[bot] avatar Sep 26 '23 00:09 github-actions[bot]

This PR is being marked as stale due to inactivity.

github-actions[bot] avatar Oct 20 '23 00:10 github-actions[bot]

This PR is being closed due to inactivity. Please reopen if work is intended to be continued.

github-actions[bot] avatar Oct 28 '23 00:10 github-actions[bot]

hey there, not sure to understand what is the goal with these tests, we seem to mostly assess if the right css class is assigned but we are not really testing the behaviour of the component here, is it wanted and if yes what is the added benefit of these tests ?

ThyMinimalDev avatar Nov 16 '23 08:11 ThyMinimalDev

HI @ThyMinimalDev in this specific case, since we are using a dropdown from the react-select library, we can customize any specific parts of this component using these props (valueContainer, input, control, etc). So we are testing if this props is working properly in this case. We are also testing if the component has the correct behavior when is loading.

gitstart-calcom avatar Nov 22 '23 13:11 gitstart-calcom

@zomars we are getting heap issues here in the unit tests. Any recs based on recent changes you’ve made around this?

keithwillcode avatar Jan 22 '24 12:01 keithwillcode