X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=DEVELOP.md;h=6eb43fb199bb5d195fcb751ef383295e2d415935;hb=59ee387ba6d5113ceedba2b16b1c0c53ddfa072c;hp=8ddf0241b9075b90dcba180a08ecd7e4a09903ed;hpb=45f8bcca3236cf514531cb1344643ef514b6dc1f;p=dygraphs.git diff --git a/DEVELOP.md b/DEVELOP.md index 8ddf024..6eb43fb 100644 --- a/DEVELOP.md +++ b/DEVELOP.md @@ -6,21 +6,37 @@ This is a step-by-step guide explaining how to do it. ### How-to +To install dependencies, run + + npm install + To build dygraphs, run - gulp dist + npm run build To run the tests, run: - gulp test + npm run build-tests + npm run test + +To iterate on the code, run: + + npm run watch + +and open `tests/demo.html` (or one of the other demos) in your browser. + +To iterate on a unit test, run the `watch` command above and open + + auto_tests/runner.html -To iterate on the code, open `tests/demo.html` (or one of the other demos) in your browser. +in your browser. You can use the Mocha UI to run just a single test or suite. +Or you can change `it` to `it.only` to do run just one test in code. -To iterate on a unit test, change `it` to `it.only` in the Mocha test. Then run +To run a single test from the command line, you can use: - ./node_modules/karma/bin/karma start auto_tests/chrome.karma.conf.js + npm run test -- --grep highlight-series-background -and hit "DEBUG" in the Karma UI. +(Note the extra `--`.) ### dygraphs style