|
| 1 | +# IDE |
| 2 | + |
| 3 | +The **Intellij Idea** is recommended. |
| 4 | + |
| 5 | +# Settings |
| 6 | + |
| 7 | +## Importing the project |
| 8 | + |
| 9 | +This is the Gradle project. |
| 10 | + |
| 11 | + |
| 12 | + |
| 13 | +Be sure that: |
| 14 | + |
| 15 | +- The `JAVA_HOME` environmental contains a path to JDK > 7 |
| 16 | + |
| 17 | +- If non built-in gradle distribution is used then its version should be > 2.1 |
| 18 | + |
| 19 | +## Compiler |
| 20 | + |
| 21 | +This project is compiled in some not common way. We use `ecj` Eclipse Java Compiler. Below is the sample how to define this compiler by IDE. |
| 22 | + |
| 23 | + |
| 24 | +## JDK |
| 25 | + |
| 26 | +Please check following settings: |
| 27 | + |
| 28 | + |
| 29 | + |
| 30 | + |
| 31 | + |
| 32 | + |
| 33 | + |
| 34 | + |
| 35 | + |
| 36 | + |
| 37 | + |
| 38 | +## Coding Standards |
| 39 | + |
| 40 | +Appium java-client strictly follows [Google Java Style](http://google-styleguide.googlecode.com/svn/trunk/javaguide.html) as a coding standards. Contributors are requested to follow this by configuring in their IDE's Editor Code style, |
| 41 | + |
| 42 | +* Clone [Google Style Guide](https://github.com/google/styleguide.git) from git |
| 43 | + |
| 44 | +**Intellij IDEA** users can configure this way, |
| 45 | +`Files -> Other Settings -> Default Settings ->Editor -> Code Style -> Manage -> Manage -> Import -> eclipse-java-google-style.xml (Downloaded from Google Style Guide)-> Apply` |
| 46 | + |
| 47 | +Reformat your code before raising a Pull Request. |
| 48 | + |
| 49 | + |
| 50 | +## Code Coverage |
| 51 | + |
| 52 | +`jacoco-maven-plugin` generates the coverage reports, once integration tests are successfully run by `maven-surefire-plugin` |
| 53 | + |
| 54 | +**Intellij IDEA** user's can configure and view this way, |
| 55 | +`Analyse -> show coverage Data -> Add -> Select ${basedir}/target/coverage-reports/jacoco-unit.exec (jacoco-unit.exec generated after integration test run) -> Click Show Selected -> Coverage Results displayed in IDE` |
| 56 | + |
| 57 | +# Please do not forget to check the code before the pull-request proposal. |
| 58 | + |
| 59 | +It is needed to go to the directory where `java_client` is located. You can do it via command line. And then run the following command |
| 60 | + |
| 61 | +`gradle check`. If everything is ok then all checks should be passed. Otherwise you can open reports at `JAVA_CLIENT_DIRECTORY/build/reports` |
| 62 | + |
| 63 | +**The adding of new tests is required when new feature is added or some bug is fixed.** |
0 commit comments