1# Contributing
2Want to contribute? Great! First, read this page.
3
4
5## Before you contribute
6Before we can use your code, you must sign the
7[Google Individual Contributor License Agreement]
8(https://cla.developers.google.com/about/google-individual)
9(CLA), which you can do online. The CLA is necessary mainly because you own the
10copyright to your changes, even after your contribution becomes part of our
11codebase, so we need your permission to use and distribute your code. We also
12need to be sure of various other things—for instance that you'll tell us if you
13know that your code infringes on other people's patents. You don't have to sign
14the CLA until after you've submitted your code for review and a member has
15approved it, but you must do it before we can put your code into our codebase.
16Before you start working on a larger contribution, you should get in touch with
17us first through the issue tracker with your idea so that we can help out and
18possibly guide you. Coordinating up front makes it much easier to avoid
19frustration later on.
20
21### The small print
22Contributions made by corporations are covered by a different agreement than
23the one above, the
24[Software Grant and Corporate Contributor License Agreement](https://cla.developers.google.com/about/google-corporate).
25
26## Pre-submit Steps
27
28### Code reviews
29All submissions, including submissions by project members, require review. We
30use GitHub pull requests for this purpose.
31
32### Testing
33To run the unit tests for Mobly to verify your local changes:
34
35Make sure you have `tox` installed:
36```sh
37pip3 install tox
38```
39
40Then in the Mobly directory, run:
41```sh
42mobly $ tox
43```
44
45### Code style
46Before pushing your changes, you need to lint the code style via `pyink`
47
48To install `pyink`:
49
50```sh
51$ pip3 install pyink
52```
53
54To lint the code:
55
56```sh
57mobly $ pyink .
58```
59