Skip to content
Irene Ros edited this page Feb 18, 2014 · 3 revisions

Running/Writing tests

The test suite for d3.chart is written using the following libraries:

Tests are located in the test/tests/*.js directory.

Running the tests:

Run grunt or grunt test or Open the test/index.html file in your browser to run the tests.

Writing new tests:

When submitting a pull request for a new feature/bug report, please add a corresponding test to allow us to verify the issue and your fix. A few rules about the tests:

  1. Do write tests to accompany your pull request.
  2. Do not test internal API.
  3. Do not inspect internal properties for checking state.
  4. Do use spies/stubs and mocks where appropriate.
  5. Do position your tests in the appropriate place in the test/tests/*.js files.
Clone this wiki locally