UNPKG

@wix/design-system

Version:

@wix/design-system

47 lines (35 loc) 1.34 kB
## Skeleton Testkit ### Import - unidriver: `import { SkeletonUniDriver } from '@wix/design-system/dist/testkit/unidriver';` - vanilla: `import { SkeletonTestkit } from '@wix/design-system/dist/testkit';` - puppeteer: `import { SkeletonTestkit } from '@wix/design-system/dist/testkit/puppeteer';` - playwright: `import { SkeletonTestkit } from '@wix/design-system/dist/testkit/playwright';` ### API ### exists - signature: exists() - returns: Promise<boolean> - description: Checks whether the component found with the given data hook ### element - signature: element() - returns: Promise<any> - description: Gets the component root element ### click - signature: click() - returns: Promise<void> - description: Clicks on the component root element ### base - signature: base() - returns: UniDriver - description: Returns UniDriver for the base element ### getNumLines - signature: getNumLines() - description: return number of lines rendered ### hasSpacing - signature: hasSpacing(spacing) - description: return boolean representing whether given spacing is rendered ### hasSizes - signature: hasSizes(sizes) - description: return boolean representing whether given list of sizes is rendered ### hasAlignment - signature: hasAlignment(alignment) - description: return boolean representing whether given alignment is rendered