Skip to content

feat: Add test coverage for Accordion component#35

Merged
kyechan99 merged 2 commits intomainfrom
copilot/add-accordion-component
Feb 3, 2026
Merged

feat: Add test coverage for Accordion component#35
kyechan99 merged 2 commits intomainfrom
copilot/add-accordion-component

Conversation

Copy link
Contributor

Copilot AI commented Feb 3, 2026

Adds comprehensive test suite for the Accordion component family (Accordion, AccordionItem, AccordionTrigger, AccordionContent).

Changes

  • Test Coverage: 10 tests covering single/multiple modes, default values, disabled states, custom indicators, and accessibility attributes

Component API

// Single mode - only one item open at a time
<Accordion type="single" defaultValue="item-2">
  <AccordionItem value="item-1">
    <AccordionTrigger>First Item</AccordionTrigger>
    <AccordionContent>Content here</AccordionContent>
  </AccordionItem>
  <AccordionItem value="item-2">
    <AccordionTrigger>Second Item</AccordionTrigger>
    <AccordionContent>Content here</AccordionContent>
  </AccordionItem>
</Accordion>

// Multiple mode - multiple items can be open
<Accordion type="multiple" defaultValue={['item-1', 'item-2']}>
  {/* ... */}
</Accordion>

The component implementation includes smooth height animations, full ARIA support, and customizable indicators.

Original prompt

This section details on the original issue you should resolve

<issue_title>feat: Accordion</issue_title>
<issue_description>### common ui

  • Accordion

feature

  • Accordion
  • AccordionItem
  • AccordionTrigger
  • AccordionContent</issue_description>

<agent_instructions>Whether the added code affects existing code, is likely to cause errors, and is general enough to use.
</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: kyechan99 <14146566+kyechan99@users.noreply.github.com>
Copilot AI changed the title [WIP] Add Accordion component and its related items feat: Add test coverage for Accordion component Feb 3, 2026
Copilot AI requested a review from kyechan99 February 3, 2026 12:30
@github-actions
Copy link

github-actions bot commented Feb 3, 2026

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 82.87% 3382 / 4081
🔵 Statements 82.87% 3382 / 4081
🔵 Functions 69% 69 / 100
🔵 Branches 77.35% 222 / 287
File CoverageNo changed files found.
Generated in workflow #122 for commit 95956f8 by the Vitest Coverage Report Action

@kyechan99 kyechan99 marked this pull request as ready for review February 3, 2026 12:57
Copy link
Member

@kyechan99 kyechan99 left a comment

Choose a reason for hiding this comment

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

LGTM

@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.87%. Comparing base (445dbc2) to head (95956f8).

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #35      +/-   ##
==========================================
+ Coverage   80.34%   82.87%   +2.52%     
==========================================
  Files          84       84              
  Lines        4081     4081              
  Branches      239      256      +17     
==========================================
+ Hits         3279     3382     +103     
+ Misses        802      699     -103     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@kyechan99 kyechan99 merged commit 116b7c7 into main Feb 3, 2026
2 checks passed
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.

feat: Accordion

3 participants

Comments