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

fix: test cases by remove tightly coupled publication ids #2494

Merged
merged 1 commit into from
Apr 11, 2023
Merged

Conversation

bigint
Copy link
Member

@bigint bigint commented Apr 11, 2023

What does this PR do?

🤖 Generated by Copilot at ddd5e39

This pull request refactors the data-testid attributes and the tests for the PublicationStats component in the web app. It improves the readability and reliability of the code and the tests by using shorter and more consistent identifiers and avoiding hard-coded values.

Related issues

Fixes # (issue)

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Enhancement (non-breaking small changes to existing functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Explanation of the changes

🤖 Generated by Copilot at ddd5e39

  • Simplify data-testid attributes of comment, mirror, like, and collect stats elements in PublicationStats.tsx (link, link, link)
  • Update tests for comment, mirror, like, and collect stats elements in publication.spec.ts to use getByTestId method twice with parent and child elements (link, link, link)
  • Use variables for publication ids in tests for publication image, video, audio, audio cover, oembeds, and snapshot widget in publication.spec.ts to avoid repetition (link, link, link, link, link)

Emoji

🧹🧪🚀

@vercel
Copy link

vercel bot commented Apr 11, 2023

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

Name Status Preview Updated (UTC)
prerender ✅ Ready (Inspect) Visit Preview Apr 11, 2023 7:35am
web ✅ Ready (Inspect) Visit Preview Apr 11, 2023 7:35am

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.

None yet

1 participant