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

NEXT: Automated Testing #2363

Open
4 of 6 tasks
endigo9740 opened this issue Dec 26, 2023 · 3 comments
Open
4 of 6 tasks

NEXT: Automated Testing #2363

endigo9740 opened this issue Dec 26, 2023 · 3 comments
Assignees
Labels
administration Items related to the project but outside the code.
Milestone

Comments

@endigo9740
Copy link
Contributor

endigo9740 commented Dec 26, 2023

As part of Skeleton v3, we'll implement support for multiple frontend frameworks. We'll likely want to consolidate on a common and universal testing tool. For this we'll opt for Vitest.

Tasks

  • Install and configure Vitest: https://vitest.dev/
  • Install and configure Testing Library: https://testing-library.com/docs/
  • Use the Accordion component as our initial reference
  • Update the Contributor guide to provide our requirements for testing
  • Update existing components that pre-date testing implementation
  • ONGOING: verify new features implement test cases

Goal

See: #150

We need to ensure we have an adequate depth and quality of test cases per component. This will make it easier to introduce new features, handle refactors, and of course improve general QA testing. With the ultimate goal of ensuring we have a set of simple and robust test cases that are not too rigid.

Some component design and features are still in flux, so aim to ensure that tests may need to be improved over time.

References:

Feedback

If you have additional updates or requests for this feature, please do so in the comments section below.

@endigo9740 endigo9740 added the administration Items related to the project but outside the code. label Dec 26, 2023
@endigo9740 endigo9740 added this to the v3.0 (Next) milestone Dec 26, 2023
@Hugos68
Copy link
Contributor

Hugos68 commented Dec 28, 2023

I'd think Testing Library will be beneficial for cross framework component testing because the sheer amount of frameworks they support. This will allow for a familliar testing API no matter what framework is being tested on.
From the last time I used it, it is compatible with vitest meaning we don't need 2 test runners. It would simply provide a virtual dom to mount and test components in.

@endigo9740
Copy link
Contributor Author

endigo9740 commented Dec 28, 2023

Yeah that's been my thought as well. We actually use Testing Library already for Skeleton v2.

(Though I really hate the name - it's so generic you can't google for anything you need! Grr! :D)

@endigo9740 endigo9740 pinned this issue Mar 20, 2024
@endigo9740 endigo9740 added Svelte - Incomplete The Svelte portion of this feature is incomplete React - Incomplete The React portion of this feature is incomplete labels Mar 21, 2024
@endigo9740 endigo9740 unpinned this issue Apr 1, 2024
@endigo9740 endigo9740 removed Svelte - Incomplete The Svelte portion of this feature is incomplete React - Incomplete The React portion of this feature is incomplete labels Apr 11, 2024
@endigo9740
Copy link
Contributor Author

endigo9740 commented Oct 3, 2024

See also type testing in Vitest: https://youtu.be/mWK3Y_1kmaM?si=64rMT3KiSCz7MQ0p&t=29214

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
administration Items related to the project but outside the code.
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

5 participants