ava-browser-fixtures
A module which adds a Browser Environment to your Ava Test.
When your Code modifies the DOM or needs some HTML to run, you can setup these
HTML-File as a Fixture can access them by the usual Browser-API (i.e.:
document.querySelector()
) with this module.
Install
Install this module with npm
or yarn
.
NPM:
npm install --save-dev ava-browser-fixture
Yarn:
yarn add --dev ava-browser-fixture
Setup
Add ava-browser-fixture
to the require
block for ava in your package.json
:
Example:
usage
Setup your fixture in the beforeEach block:
;; test; ;