Skip to content

Commit f07c57c

Browse files
committed
feat: add server-test alias for #23
1 parent 6c1bdbe commit f07c57c

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@ npm install --save-dev start-server-and-test
1919

2020
## Use
2121

22-
This command is meant to be used with NPM script commands. If you have a "start server",
23-
and "test" script names for example, you can start the server, wait for a url to respond,
24-
then run tests. When the test process exits, the server is shut down.
22+
This command is meant to be used with NPM script commands. If you have a "start server", and "test" script names for example, you can start the server, wait for a url to respond, then run tests. When the test process exits, the server is shut down.
2523

2624
```json
2725
{
@@ -35,6 +33,10 @@ then run tests. When the test process exits, the server is shut down.
3533

3634
To execute all tests simply run `npm run ci`
3735

36+
### Alias
37+
38+
You can use either `start-server-and-test` or `server-test` commands in your scripts.
39+
3840
### Options
3941

4042
If you use convention and name your scripts "start" and "test" you can simply provide URL

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"author": "Gleb Bahmutov <[email protected]>",
66
"bugs": "https://github.com/bahmutov/start-server-and-test/issues",
77
"bin": {
8-
"start-server-and-test": "bin/start.js"
8+
"start-server-and-test": "bin/start.js",
9+
"server-test": "bin/start.js"
910
},
1011
"config": {
1112
"pre-git": {

0 commit comments

Comments
 (0)