1.2.1 • Published 1 year ago
@velmalabs/testsuite v1.2.1
Velma - Test Suite
This package contains the test suite of Velma.
What is Test Suite?
This package makes it easy to test svelte 5 components using playwright.
Installation
Run the following command to install the package:
npm install @velmalabs/testsuiteUsage
To use this package, you can run the following command:
npm testsuite [playwright options]Examples
Run tests in headless mode
npm testsuiteRun tests in ui mode
npm testsuite --uiRun tests in headless mode with specific browser
npm testsuite --browser=firefoxWriting Tests
To write tests, you can create a file with the .test.js extension in your project.
import {render, test, expect} from "@velmalabs/testsuite";
test('button', async () => {
let clicked = false;
const screen = await render('./Button.svelte', {
text: 'Hello',
onclick: () => clicked = true
});
const button = screen.locator('button');
await button.click();
expect(clicked).toBe(true);
});Resources
1.2.0
1 year ago
1.1.1
1 year ago
1.0.2
1 year ago
1.1.0
1 year ago
1.0.1
1 year ago
1.0.0
1 year ago
1.1.9
1 year ago
1.1.8
1 year ago
1.0.9
1 year ago
1.1.7
1 year ago
1.0.8
1 year ago
1.1.6
1 year ago
1.0.7
1 year ago
1.1.4
1 year ago
1.0.5
1 year ago
1.1.3
1 year ago
1.0.4
1 year ago
1.2.1
1 year ago
1.1.2
1 year ago
1.0.3
1 year ago
1.1.12
1 year ago
1.1.11
1 year ago
1.1.10
1 year ago
1.0.11
1 year ago
1.0.10
1 year ago
0.1.16
1 year ago
0.1.15
1 year ago
0.1.14
1 year ago
0.1.13
1 year ago
0.1.12
1 year ago
0.1.11
1 year ago
0.1.10
1 year ago
0.1.9
1 year ago
0.1.8
1 year ago
0.1.7
1 year ago
0.1.6
1 year ago
0.1.5
1 year ago
0.1.4
1 year ago
0.1.3
1 year ago
0.1.2
1 year ago
0.1.1
1 year ago
0.1.0
1 year ago