Skip to content

Commit

Permalink
update dependencies + added some github actions + updated *.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexandre Oger committed Oct 19, 2024
1 parent 2da058b commit 74720ae
Show file tree
Hide file tree
Showing 12 changed files with 3,045 additions and 5,970 deletions.
4 changes: 3 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ updates:
- package-ecosystem: 'npm' # See documentation for possible values
directory: '/' # Location of package manifests
schedule:
interval: 'daily'
interval: 'weekly'
open-pull-requests-limit: 10
versioning-strategy: increase
36 changes: 28 additions & 8 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,41 @@ on:

jobs:
build_and_test:
name: Build and test
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20]

steps:
- name: Check out code
uses: actions/checkout@v4
- uses: actions/checkout@v4

- name: Install NPM dependencies
run: yarn install --frozen-lockfile
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'

- name: Install dependencies
run: pnpm install

- name: Lint
run: yarn run lint
run: pnpm run lint

- name: Test
run: yarn run test
run: pnpm run test

- name: Coverage
run: pnpm run coverage

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}

- name: Build
run: yarn run build
run: pnpm run build
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ dist
dist-ssr
*.local

# vite
vite.config.ts.timestamp-*.mjs

# Editor directories and files
.vscode/*
!.vscode/extensions.json
Expand Down
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.0.55] - 2024-10-19

### Added

- CI: added `Codecov` coverage reporting and build performance
- Added a `CHANGELOG.md`
- CI: added prepublishOnly

### Changed

- CI: changed `dependabot` schedule from `daily` to `weekly`
- Updated dependencies
- Enhanced the contributing section in `README.md`
- Added more strict rules in `tsconfig.json`

[0.0.55]: https://github.com/nielk/idonttrustlikethat-fast-check/releases/tag/v0.0.55
67 changes: 61 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
![last commit](https://img.shields.io/github/last-commit/nielk/idonttrustlikethat-fast-check)
![npm bundle size](https://img.shields.io/bundlephobia/minzip/idonttrustlikethat-fast-check)
![npm](https://img.shields.io/npm/v/idonttrustlikethat-fast-check)
[![codecov](https://codecov.io/github/nielk/idonttrustlikethat-fast-check/graph/badge.svg?token=USWA5N026O)](https://codecov.io/github/nielk/idonttrustlikethat-fast-check)
![license](https://img.shields.io/npm/l/idonttrustlikethat-fast-check.svg)

## Table of Contents
Expand Down Expand Up @@ -223,7 +224,7 @@ In this example, arbitrary will be a randomly generated array that satisfies the

### Unsupported validators

The following validators are not supported:
Despicte my will to support the following validators (I asked the idonttrustlikethat author to make change to make it possible, but had no responses… 😪), they are not supported:

```
- discriminatedUnion
Expand All @@ -235,15 +236,69 @@ The following validators are not supported:

## Contributing

## Build manually
We welcome contributions to idonttrustlikethat-fast-check! Here's how you can help:

### Reporting Issues

If you find a bug or have a feature request:

1. Search the [issue tracker](https://github.com/nielk/idonttrustlikethat-fast-check/issues) to ensure it hasn't been reported before.
2. If not found, [open a new issue](https://github.com/nielk/idonttrustlikethat-fast-check/issues/new), providing as much detail as possible.

### Contributing Code

1. Fork the repository and create your branch from `main`.
2. Clone your fork and install dependencies:
```
git clone https://github.com/your-username/idonttrustlikethat-fast-check.git
cd idonttrustlikethat-fast-check
pnpm install
```
3. Make your changes, adding tests for new functionality.
4. Ensure all tests pass:
```
pnpm run test
```
5. Run the build process:
```
pnpm run build
```
6. Commit your changes using a descriptive commit message.
7. Push to your fork and [submit a pull request](https://github.com/nielk/idonttrustlikethat-fast-check/compare).

### Code Style

- Follow the existing code style.
- Use meaningful variable names and add comments for complex logic.
- Write clear commit messages.

### Running Tests

To run the test suite:

```
yarn install # If need
yarn run build
yarn run test
pnpm run test
```

Contributions are welcome! If you find a bug or have a feature request, please open an issue. If you'd like to contribute code, please fork the repository and submit a pull request.
For coverage report:

```
pnpm run coverage
```

### Documentation

Improvements to documentation are always welcome. This includes:

- README.md updates
- Code comments
- Examples in the `examples/` directory

### Questions?

Feel free to open an issue for any questions about contributing.

Thank you for contributing to idonttrustlikethat-fast-check!

# License

Expand Down
63 changes: 35 additions & 28 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
{
"name": "idonttrustlikethat-fast-check",
"private": false,
"version": "0.0.53",
"version": "0.0.55",
"type": "module",
"description": "idonttrustlikethat-fast-check is a plugin designed for fast-check. It convert idonttrustlikethat validators to fast-check arbitraries. Allowing the possibility to use idtlt validators with fast-check.",
"keywords": [
"idonttrustlikethat",
"idtlt",
"fast-check",
"@fast-check",
"plugin"
"plugin",
"validation",
"testing",
"property-based-testing",
"typescript"
],
"author": "Alexandre Oger <[email protected]>",
"engines": {
Expand Down Expand Up @@ -37,51 +41,54 @@
}
},
"typings": "./dist/main.d.ts",
"sideEffects": false,
"license": "MIT",
"scripts": {
"dev": "vite",
"build": "tsc && yarn format && yarn test && vite build",
"build": "tsc && pnpm format && pnpm test && vite build",
"build:watch": "tsc && vite build --watch",
"lint": "./node_modules/.bin/eslint src test && yarn prettier . --check && oxlint -A all",
"format": "./node_modules/.bin/eslint src test --fix && yarn prettier . --write && oxlint -A all --fix",
"test": "vitest --run --typecheck",
"lint": "./node_modules/.bin/eslint src test && pnpm prettier . --check && oxlint -A all",
"format": "./node_modules/.bin/eslint src test --fix && pnpm prettier . --write && oxlint -A all --fix",
"test": "vitest run --typecheck",
"test:watch": "vitest --typecheck",
"test:ui": "vitest --ui --typecheck",
"test:ui": "vitest --ui --typecheck --coverage.enabled=true",
"coverage": "vitest run --coverage",
"update:deps": "pnpm up --latest -i",
"prepublishOnly": "pnpm build",
"knip": "knip"
},
"peerDependencies": {
"fast-check": ">3.15.0 latest",
"idonttrustlikethat": ">2.1.0 latest"
},
"devDependencies": {
"@eslint/compat": "1.1.0",
"@codecov/vite-plugin": "1.2.1",
"@eslint/compat": "1.2.1",
"@eslint/eslintrc": "3.1.0",
"@eslint/js": "9.5.0",
"@rollup/plugin-typescript": "11.1.6",
"@eslint/js": "9.13.0",
"@rollup/plugin-typescript": "12.1.1",
"@types/eslint__js": "8.42.3",
"@types/node": "20.14.8",
"@typescript-eslint/eslint-plugin": "7.14.1",
"@typescript-eslint/parser": "7.14.1",
"@vitest/coverage-v8": "1.6.0",
"@vitest/ui": "1.6.0",
"eslint": "9.5.0",
"@types/node": "22.7.7",
"@typescript-eslint/eslint-plugin": "8.10.0",
"@typescript-eslint/parser": "8.10.0",
"@vitest/coverage-v8": "2.1.3",
"@vitest/ui": "2.1.3",
"eslint": "9.13.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-import": "2.29.1",
"eslint-plugin-prettier": "5.1.3",
"fast-check": "3.19.0",
"globals": "15.6.0",
"eslint-plugin-import": "2.31.0",
"eslint-plugin-prettier": "5.2.1",
"fast-check": "3.22.0",
"globals": "15.11.0",
"idonttrustlikethat": "2.1.2",
"knip": "5.22.3",
"oxlint": "0.4.4",
"prettier": "3.3.2",
"knip": "5.33.3",
"oxlint": "0.10.0",
"prettier": "3.3.3",
"rollup-plugin-typescript-paths": "1.5.0",
"tslib": "2.6.3",
"typescript": "5.5.2",
"typescript-eslint": "7.14.1",
"vite": "5.3.1",
"vitest": "1.6.0"
"tslib": "2.8.0",
"typescript": "5.6.3",
"typescript-eslint": "8.10.0",
"vite": "5.4.9",
"vitest": "2.1.3"
},
"resolutions": {
"braces": ">=3.0.3"
Expand Down
Loading

0 comments on commit 74720ae

Please sign in to comment.