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

test(atomic): start tests on atomic-commerce-facets #4071

Merged
merged 28 commits into from
Jun 18, 2024
Merged

test(atomic): start tests on atomic-commerce-facets #4071

merged 28 commits into from
Jun 18, 2024

Conversation

olamothe
Copy link
Member

@olamothe olamothe commented Jun 10, 2024

Mostly: Add new base-page-object to inherit from for each tests, which should simplify/streamline the "load this story for this component with these arguments in the URL" repetitive pattern.

https://coveord.atlassian.net/browse/KIT-3256

@developer-experience-bot
Copy link
Contributor

developer-experience-bot bot commented Jun 10, 2024

Pull Request Report

PR Title

❌ Title should follow the conventional commit spec:
<type>(optional scope): <description>

Example: feat(headless): add result-list controller

Live demo links

Bundle Size

File Old (kb) New (kb) Change (%)
case-assist 204.8 204.8 0
commerce 292.6 292.6 0
search 372.3 372.3 0
insight 352.3 352.3 0
product-listing 266.9 266.9 0
product-recommendation 170.8 170.8 0
recommendation 217.8 217.8 0
ssr 365.1 365.1 0

SSR Progress

Use case SSR (#) CSR (#) Progress (%)
search 39 44 89
recommendation 0 4 0
product-recommendation 0 10 0
product-listing 0 13 0
case-assist 0 6 0
insight 0 27 0
commerce 0 15 0
Detailed logs search : buildInteractiveResult
search : buildInteractiveInstantResult
search : buildInteractiveRecentResult
search : buildInteractiveCitation
search : buildGeneratedAnswer
recommendation : missing SSR support
product-recommendation : missing SSR support
product-listing : missing SSR support
case-assist : missing SSR support
insight : missing SSR support
commerce : missing SSR support

Copy link
Collaborator

@louis-bompart louis-bompart left a comment

Choose a reason for hiding this comment

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

I'm not fond of those tests/utils if I'm perfectly honest.
I think we should try to adhere more closely to the modern test philosophy shared across all modern test frameworks, which entails testing user-visible behaviour.
https://playwright.dev/docs/best-practices#test-user-visible-behavior
https://testing-library.com/docs/guiding-principles

What does that mean for this PR?

  1. packages/atomic/src/components/commerce/facets/atomic-commerce-facets/e2e/page-object.ts should have locators built around the facet labels
  2. The utils should make lighter uses of the hydrated selector.

packages/atomic/playwright-utils/base-page-object.ts Outdated Show resolved Hide resolved
@olamothe olamothe enabled auto-merge June 18, 2024 14:06
@olamothe olamothe added this pull request to the merge queue Jun 18, 2024
Merged via the queue into master with commit 8af33c1 Jun 18, 2024
92 checks passed
@olamothe olamothe deleted the KIT-3256 branch June 18, 2024 14:40
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