With this plugin for webdriver.io it is easy to properly cleanup after each test. Cleanup after test might get complicated. For example: Lets say you are creating a bank account and then adding an investment plan and depositing there some money. If you try to delete the account you'd probably get a refusion because the account is not empty. cleanup-total helps you to do it systematically by 'marking' each entity you create for deletion right after its creation. When the test is finished, cleanup-total would delete the investment plan, the deposit and the account in the right order.
InstallationThe easiest way to install this module as a (dev-)dependency is by using the following command:
Add wdio-cleanuptotal-service to your
or with the service options:
Usage in test
Just import cleanuptotal where you need it, whether it be your test file or any other class:
Typescript is supported for this plugin.