Tone.js/test/README.md

18 lines
1.1 KiB
Markdown
Raw Normal View History

2015-10-21 17:14:19 +00:00
`gulp test` from within the gulp folder to start a server and run all of the tests.
Individual files can be tested by running `gulp collectTests -f [Tone class name]` which will update the test/Main.js with the given class tests.
You can also test groups of classes by folder by adding another flag. For example to test all of the signals run `gulp collectTests --signal`. or the shorthand form: `gulp collectTests -s`.
* `-s` = `--signal`
* `-i` = `--instrument`
* `-o` = `--source`
2015-11-04 20:59:09 +00:00
* `-v` = `--event`
2015-10-21 17:14:19 +00:00
* `-e` = `--effect`
* `-c` = `--core`
* `-m` = `--component`
2015-11-04 20:59:09 +00:00
* `-t` = `--control`
2015-10-21 17:14:19 +00:00
Currently, Chrome is the target test platform. 100% of tests should pass. Fewer tests tends to pass in Safari and even fewer in Firefox. The goal is to have 100% pass on all browsers, but since the speicification and implementations are all relatively new, there are still a few kinks to work out.
2015-11-04 20:59:09 +00:00
Be sure that the browser window is in focus while tests are running. Timing in Tone.js is done using requestAnimationFrame which fires at a low priority or no priority if the tab is not in focus.