Skip to content

Commit d7924ff

Browse files
committed
Add a custom composer script to run tests
1 parent 508efd3 commit d7924ff

File tree

4 files changed

+19
-3
lines changed

4 files changed

+19
-3
lines changed

.github/workflows/run-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,4 @@ jobs:
4343
COMPOSER_AUTH: ${{ secrets.COMPOSER_AUTH }}
4444

4545
- name: Execute tests
46-
run: vendor/bin/phpunit
46+
run: composer test

composer.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,8 @@
4545
"sort-packages": true
4646
},
4747
"minimum-stability": "dev",
48-
"prefer-stable": true
48+
"prefer-stable": true,
49+
"scripts": {
50+
"test": "phpunit"
51+
}
4952
}

docs/CONTRIBUTING.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
1-
21
## Compiling Assets
32

3+
```bash
4+
# Install npm dependencies
5+
npm install
6+
```
7+
48
```bash
59
# Compile and minify your assets:
610
npm run prod
@@ -11,3 +15,9 @@ npm run dev
1115
# Run the NPM "watch" command to auto-compile your assets when they are changed:
1216
npm run watch
1317
```
18+
19+
## Run tests
20+
21+
```bash
22+
composer test
23+
```

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
{
22
"private": true,
3+
"engines": {
4+
"node": ">=16.0"
5+
},
36
"scripts": {
47
"dev": "npm run development",
58
"development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",

0 commit comments

Comments
 (0)