mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
add test_unit_app task
This commit is contained in:
parent
103ddd79ef
commit
a9f1989eca
3 changed files with 10 additions and 0 deletions
|
@ -187,6 +187,9 @@ test: test_unit test_frontend test_acceptance
|
|||
test_unit:
|
||||
npm -q run test:unit -- ${MOCHA_ARGS}
|
||||
|
||||
test_unit_app:
|
||||
npm -q run test:unit:app -- ${MOCHA_ARGS}
|
||||
|
||||
test_frontend: test_clean # stop service
|
||||
$(MAKE) compile
|
||||
docker-compose ${DOCKER_COMPOSE_FLAGS} up test_frontend
|
||||
|
|
6
services/web/bin/unit_test_app
Executable file
6
services/web/bin/unit_test_app
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/bash
|
||||
set -e;
|
||||
|
||||
MOCHA="node_modules/.bin/mocha --exit --recursive --reporter spec"
|
||||
|
||||
$MOCHA "$@" test/unit/js
|
|
@ -15,6 +15,7 @@
|
|||
"test:acceptance:dir": "npm -q run test:acceptance:wait_for_app && npm -q run test:acceptance:run -- $@",
|
||||
"test:acceptance": "npm -q run test:acceptance:dir -- $@ test/acceptance/js",
|
||||
"test:unit": "npm -q run compile && bin/unit_test $@",
|
||||
"test:unit:app": "npm -q run compile && bin/unit_test_app $@",
|
||||
"test:frontend": "karma start",
|
||||
"compile": "make compile",
|
||||
"start": "npm -q run compile && node $NODE_APP_OPTIONS app.js",
|
||||
|
|
Loading…
Reference in a new issue