2013-04-15 10:01:07 +02:00
|
|
|
===========================
|
|
|
|
Contributing to Converse.js
|
|
|
|
===========================
|
|
|
|
|
2013-07-28 22:51:25 +02:00
|
|
|
Thanks for contributing to Converse.js_.
|
2013-04-17 12:11:59 +02:00
|
|
|
|
|
|
|
Please follow the usual github workflow. Create your own local fork of this repository,
|
|
|
|
make your changes and then submit a pull request.
|
2013-04-15 10:01:07 +02:00
|
|
|
|
|
|
|
Before submitting a pull request
|
|
|
|
================================
|
|
|
|
|
|
|
|
Add tests for your bugfix or feature
|
|
|
|
------------------------------------
|
|
|
|
|
2013-04-17 12:11:59 +02:00
|
|
|
Add a test for any bug fixed or feature added. We use Jasmine
|
|
|
|
for testing.
|
|
|
|
|
|
|
|
Take a look at ``tests.html`` and ``spec/MainSpec.js`` to see how
|
|
|
|
the tests are implemented.
|
2013-04-15 10:01:07 +02:00
|
|
|
|
2013-07-28 22:51:25 +02:00
|
|
|
If you are unsure how to write tests, please `contact me`_ and I'll be happy to
|
|
|
|
help.
|
|
|
|
|
2013-07-29 23:22:41 +02:00
|
|
|
Check that the tests pass
|
|
|
|
-------------------------
|
2013-04-15 10:01:07 +02:00
|
|
|
|
2013-07-28 22:51:25 +02:00
|
|
|
Check that the Jasmine tests complete sucessfully. Open tests.html in your
|
2013-04-17 12:11:59 +02:00
|
|
|
browser, and the tests will run automatically.
|
|
|
|
|
2013-07-28 22:51:25 +02:00
|
|
|
On the command line you can run ``grunt test`` (if you have before run ``npm
|
|
|
|
install``).
|
|
|
|
|
2013-07-28 22:59:01 +02:00
|
|
|
Check your code for errors or bad habits by running JSHint
|
|
|
|
----------------------------------------------------------
|
|
|
|
|
|
|
|
If you haven't yet done so, run ``npm install`` to install all development
|
|
|
|
dependencies.
|
|
|
|
|
|
|
|
Then run ``grunt jshint`` and check the output.
|
|
|
|
|
2013-04-17 12:11:59 +02:00
|
|
|
.. _Converse.js: http://conversejs.org
|
2013-07-28 22:51:25 +02:00
|
|
|
.. _`contact me`: http://opkode.com/contact.html
|