[docs] Update Contributing Section in docs.

* Add testing details
* Add linting step
* Add CONTRIBUTING.md
This commit is contained in:
Giorgos Logiotatidis 2014-05-30 12:39:37 +03:00
Родитель 554a27309a
Коммит 5fda5a7e30
3 изменённых файлов: 37 добавлений и 0 удалений

1
CONTRIBUTING.md Normal file
Просмотреть файл

@ -0,0 +1 @@
Please read the [Contribution Guidelines in Mozillians.org Documentation](http://mozillians.readthedocs.org/en/latest/contribute.html).

Просмотреть файл

@ -29,10 +29,24 @@ When you want to start contributing, you should :doc:`follow the installation in
#. Commit changes to the code!
#. Code!
#. Lint the code::
$ flake8 mozillians
and fix any errors.
#. Run the tests::
$ ./manage.py test
and make sure that all tests pass.
Learn more about :doc:`testing </testing>`.
#. Commit changes to the code!
#. When you're done, figure out how many commits you've made::
$ git log

Просмотреть файл

@ -2,6 +2,28 @@
Testing
=========
Testing Mozillians Code
-----------------------
* To run mozillians.org tests::
$ ./manage.py test
* If you need a fresh test database::
$ FORCE_DB=1 ./manage.py test
* To run all tests in a class::
$ ./manage.py test mozillians.users.tests.test_models:UserProfileTests
* If you want to run a single test::
$ ./manage.py test mozillians.users.tests.test_models:UserProfileTests.test_get_attribute_with_public_level
to run only `test_get_attribute_with_public_level` test from the `UserProfileTests` class in the `mozillians/users/tests/test_models.py` test file.
Test Coverage
-------------