Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
a3a4ded41e | |||
03d478d6ff |
@ -1,5 +1,13 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 2025-05-16 - 1.9.0 - feat(docs)
|
||||||
|
Update documentation to embed tapbundle and clarify module exports for browser compatibility; also add CI permission settings.
|
||||||
|
|
||||||
|
- Embed tapbundle directly into tstest to simplify usage and ensure browser support.
|
||||||
|
- Update import paths in examples from '@push.rocks/tapbundle' to '@git.zone/tstest/tapbundle'.
|
||||||
|
- Revise the changelog to reflect version 1.8.0 improvements including enhanced test lifecycle hooks and parallel execution fixes.
|
||||||
|
- Add .claude/settings.local.json to configure CI-related permissions and tool operations.
|
||||||
|
|
||||||
## 2025-05-16 - 1.8.0 - feat(documentation)
|
## 2025-05-16 - 1.8.0 - feat(documentation)
|
||||||
Enhance README with detailed test features and update local settings for build permissions.
|
Enhance README with detailed test features and update local settings for build permissions.
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@git.zone/tstest",
|
"name": "@git.zone/tstest",
|
||||||
"version": "1.8.0",
|
"version": "1.9.0",
|
||||||
"private": false,
|
"private": false,
|
||||||
"description": "a test utility to run tests that match test/**/*.ts",
|
"description": "a test utility to run tests that match test/**/*.ts",
|
||||||
"exports": {
|
"exports": {
|
||||||
|
21
readme.md
21
readme.md
@ -26,7 +26,7 @@
|
|||||||
- ⏳ **Timeout Control** - Set custom timeouts for tests
|
- ⏳ **Timeout Control** - Set custom timeouts for tests
|
||||||
- 🔁 **Retry Logic** - Automatically retry failing tests
|
- 🔁 **Retry Logic** - Automatically retry failing tests
|
||||||
- 🛠️ **Test Fixtures** - Create reusable test data
|
- 🛠️ **Test Fixtures** - Create reusable test data
|
||||||
- 📦 **Browser-Compatible** - Full browser support for tapbundle
|
- 📦 **Browser-Compatible** - Full browser support with embedded tapbundle
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@ -143,10 +143,10 @@ tstest supports different test environments through file naming:
|
|||||||
|
|
||||||
### Writing Tests
|
### Writing Tests
|
||||||
|
|
||||||
tstest uses TAP (Test Anything Protocol) for test output. Use `@pushrocks/tapbundle` for the best experience:
|
tstest includes a built-in TAP (Test Anything Protocol) test framework. Import it from the embedded tapbundle:
|
||||||
|
|
||||||
```typescript
|
```typescript
|
||||||
import { expect, tap } from '@push.rocks/tapbundle';
|
import { expect, tap } from '@git.zone/tstest/tapbundle';
|
||||||
|
|
||||||
tap.test('my awesome test', async () => {
|
tap.test('my awesome test', async () => {
|
||||||
const result = await myFunction();
|
const result = await myFunction();
|
||||||
@ -156,6 +156,14 @@ tap.test('my awesome test', async () => {
|
|||||||
tap.start();
|
tap.start();
|
||||||
```
|
```
|
||||||
|
|
||||||
|
**Module Exports**
|
||||||
|
|
||||||
|
tstest provides multiple exports for different use cases:
|
||||||
|
|
||||||
|
- `@git.zone/tstest` - Main CLI and test runner functionality
|
||||||
|
- `@git.zone/tstest/tapbundle` - Browser-compatible test framework
|
||||||
|
- `@git.zone/tstest/tapbundle_node` - Node.js-specific test utilities
|
||||||
|
|
||||||
#### Test Features
|
#### Test Features
|
||||||
|
|
||||||
**Tag-based Test Filtering**
|
**Tag-based Test Filtering**
|
||||||
@ -243,7 +251,7 @@ tap.todo('implement user deletion', async () => {
|
|||||||
**Browser Testing**
|
**Browser Testing**
|
||||||
```typescript
|
```typescript
|
||||||
// test.browser.ts
|
// test.browser.ts
|
||||||
import { tap, webhelpers } from '@push.rocks/tapbundle';
|
import { tap, webhelpers } from '@git.zone/tstest/tapbundle';
|
||||||
|
|
||||||
tap.test('DOM manipulation', async () => {
|
tap.test('DOM manipulation', async () => {
|
||||||
const element = await webhelpers.fixture(webhelpers.html`
|
const element = await webhelpers.fixture(webhelpers.html`
|
||||||
@ -322,8 +330,9 @@ tstest test/ --quiet
|
|||||||
|
|
||||||
## Changelog
|
## Changelog
|
||||||
|
|
||||||
### Version 1.7.0
|
### Version 1.8.0
|
||||||
- 🎉 Made `@push.rocks/tapbundle` fully browser-compatible
|
- 📦 Embedded tapbundle directly into tstest project
|
||||||
|
- 🌐 Made tapbundle fully browser-compatible
|
||||||
- 📸 Added snapshot testing with base64-encoded communication protocol
|
- 📸 Added snapshot testing with base64-encoded communication protocol
|
||||||
- 🏷️ Introduced tag-based test filtering
|
- 🏷️ Introduced tag-based test filtering
|
||||||
- 🔧 Enhanced test lifecycle hooks (beforeEach/afterEach)
|
- 🔧 Enhanced test lifecycle hooks (beforeEach/afterEach)
|
||||||
|
@ -3,6 +3,6 @@
|
|||||||
*/
|
*/
|
||||||
export const commitinfo = {
|
export const commitinfo = {
|
||||||
name: '@git.zone/tstest',
|
name: '@git.zone/tstest',
|
||||||
version: '1.8.0',
|
version: '1.9.0',
|
||||||
description: 'a test utility to run tests that match test/**/*.ts'
|
description: 'a test utility to run tests that match test/**/*.ts'
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user