Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/drunomics/playwright-drupal-utils
https://github.com/drunomics/playwright-drupal-utils
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/drunomics/playwright-drupal-utils
- Owner: drunomics
- License: gpl-3.0
- Created: 2022-10-13T16:45:37.000Z (about 2 years ago)
- Default Branch: 1.x
- Last Pushed: 2024-07-24T16:11:39.000Z (6 months ago)
- Last Synced: 2024-07-25T16:02:48.258Z (6 months ago)
- Language: PHP
- Size: 68.4 KB
- Stars: 3
- Watchers: 10
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# drunomics Playwright Drupal utils
## Dependencies:
- Drush
## Overview:
The package provides:
* Various drush commands in the PlaywrightDrushCommands class useful for testing with playwright. The class is autoloaded and ready to use when package is installed.
* Test helpers and commands
* The functions in `./tests/helpers/drupal-commands` are reusable helpers for communicating with drupal API in tests.
* `./tests/helpers/ldp-test` holds a fixture, an extension of playwright test which carries additional variables suitable for testing decoupled projects with diverse origins.
* `./tests/helpers/test-methods` is a collection of reusable and often used helper functions, for example logging in and out of the site, headers check etc.
* `./tests/helpers/a11y-helper` is a helper for running accessibility checks using axe-core.
### Setup
* Add this package to your project's dev dependencies.
* Add package type "playwright-helper" to "installer-types" section of your composer.json
* Adjust the package installation location by adjusting installer-paths in your composer.json. The package needs to be installed in the directory with your playwright installation (location of your package.json).
* Require the helpers in your test files e.g. `const helpers = require("../playwright-drupal-utils/tests/helpers/test-methods");`## License
* Drush Extension is licensed under [GPLv3 or later](src/LICENSE)
* JavaScript code is licensed under [MIT](tests/LICENSE)## Credits
developed by drunomics GmbH, [email protected]
Please refer to the commit log individual contributors.