> ## Documentation Index
> Fetch the complete documentation index at: https://subframe-59800133-gtmbot-restructure-dark-mode-docs-v2.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Testing

> Add test attributes to Subframe components.

All components pass through props to the top-level element. Add `data-testid` or other test attributes for use with testing tools like Playwright, Cypress, or Selenium:

```tsx theme={null}
<Button data-testid="submit-btn" onClick={handleSubmit}>
  Submit
</Button>

<TextField data-testid="email-input" data-cy="email-field" />
```

For reusable test IDs, [create wrapper components](/concepts/syncing-components#wrapping-components) that include them by default.
