Skip to content

Commit

Permalink
adding test command
Browse files Browse the repository at this point in the history
  • Loading branch information
zoe-codez committed Mar 26, 2024
1 parent 49fe4bd commit 2529c71
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 6 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ on:
pull_request:
branches:
- main

push:
branches:
- main
jobs:
lint-and-build:
runs-on: ubuntu-latest
Expand All @@ -16,3 +18,4 @@ jobs:
- run: npm install
- run: npm run lint
- run: npm run build
- run: npm run test
7 changes: 5 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ name: Publish

on:
push:
branches:
- main
tags:
- 'v*'

jobs:
publish:
Expand All @@ -15,6 +15,9 @@ jobs:
node-version: '20'
registry-url: 'https://registry.npmjs.org/'
- run: npm i
- run: npm run lint
- run: npm run build
- run: npm run test
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

Welcome to `@digital-alchemy/mqtt-extension`!

- Extended docs: https://docs.digital-alchemy.app/MQTT
- Discord: https://discord.digital-alchemy.app
- [Extended docs](https://docs.digital-alchemy.app/MQTT)
- [Discord](https://discord.com/invite/mtWHk36upW)

## 💾 Install

Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@
"name": "@digital-alchemy/mqtt-extension",
"repository": "https://github.com/Digital-Alchemy-TS/mqtt",
"homepage": "https://docs.digital-alchemy.app/MQTT",
"version": "0.3.3",
"version": "0.3.4",
"scripts": {
"build": "rm -rf dist/; tsc",
"test": "./scripts/test.sh",
"lint": "eslint src",
"prepublishOnly": "npm run build",
"upgrade": "ncu -u; npm i"
Expand Down
2 changes: 2 additions & 0 deletions scripts/test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
NODE_OPTIONS="$NODE_OPTIONS --experimental-vm-modules" npx jest --pass-with-no-tests "$1"

0 comments on commit 2529c71

Please sign in to comment.