@wix/design-system
Version:
@wix/design-system
67 lines (50 loc) • 1.66 kB
Markdown
## Stepper Testkit
### Import
- unidriver: `import { StepperUniDriver } from '@wix/design-system/dist/testkit/unidriver';`
- vanilla: `import { StepperTestkit } from '@wix/design-system/dist/testkit';`
- puppeteer: `import { StepperTestkit } from '@wix/design-system/dist/testkit/puppeteer';`
- playwright: `import { StepperTestkit } 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
### getType
- signature: getType()
- description: Returns the style type.
### getSize
- signature: getSize()
- description: Returns size.
### getFit
- signature: getFit()
- description: Returns the fit mode.
### clickStep
- signature: clickStep(index)
- description: Click step at index.
### hoverStep
- signature: hoverStep(index)
- description: Hover step at index.
### getNumberOfSteps
- signature: getNumberOfSteps()
- description: Returns the number of rendered steps.
### isStepActive
- signature: isStepActive(index)
- description: Returns whether the step at index is active or not.
### getStepType
- signature: getStepType(index)
- description: Returns the type of step at index.
### getStepText
- signature: getStepText(index)
- description: Returns the text content of step at index.