Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,3 +160,23 @@ For teachers or developers instructing classes, you may choose to install a proj
os install -m

After selecting and confirming installation, you'll find any master files in the hidden directory of `.master`.

### Authoring Testable Projects

*For automated testing with opspark utility*
* Tests must be in a `test` directory top level of repo
* NOT spec, NOT Test, NOT tests
* `test` directory should also contain a `mocha.opts` file
* Mocha.opts file MUST have `—reporter json`
* Other mocha adjustments (timeout, etc) are optional
If projects update pages dynamically (ex. jQuery) they must be served to run tests
* Example here https://github.com/livrush/product-project/tree/test
* `Server.js` (or other named server file) MUST be in `test` directory
* Running `mocha ./test/products.spec.js` also runs server.js
* Mocha 3.4.1 seems to run all files in the specified directory, allowing the project to be served, then it is imported into the tests using zombie.
Script to run tests MUST be input as `npm test` in `package.json`.
* Doesn’t matter if it’s mocha/qunit/jasmine/whatever
* Technically opspark only runs with mocha at the moment, since it gets the results from mocha json reporter.
* If you need to run multiple scripts, they can all happen in `npm test`.
`package.json` must be in top level of repo as well