test(docs-infra): add commands to run the unit tests (#34537)

This commit adds the necessary custom commands to run the tests in a
node environment.

PR Close #34537
This commit is contained in:
Sonu Kapoor 2020-08-22 13:16:17 +03:00 committed by Joey Perrott
parent fedcfec346
commit 164cd274a4
2 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,9 @@
/*
* This example project is special in that it is not a cli app. To run tests appropriate for this
* project, the test command is overwritten in `aio/content/examples/observables/example-config.json`.
*
* This is an empty placeholder file to ensure that `aio/tools/examples/run-example-e2e.js` runs
* tests for this project.
*
* TODO: Fix our infrastructure/tooling, so that this hack is not necessary.
*/

View File

@ -0,0 +1,12 @@
{
"tests": [
{
"cmd": "yarn",
"args": ["tsc", "--project", "tsconfig.spec.json", "--module", "commonjs"]
},
{
"cmd": "yarn",
"args": ["jasmine", "out-tsc/**/*.spec.js"]
}
]
}