Testing the components
Testing the components
How we've built the components
Typically, components sit in the DOM, also known as the
At the core, the UI Kit components are based off the web components specification, which utilises the shadow DOM. This makes it possible to encapsulate each component’s markup structure, styling and functionality.
According to
Therefore, testing components within the shadow DOM can be problematic because elements inside a shadow root technically do not exist in the main DOM, and can prevent testing frameworks from selecting internal elements.
Testing the components
To ease the process of testing, here are guides to testing our UI Kit components in different testing frameworks.