Skip to content
Rafal edited this page Mar 8, 2014 · 7 revisions

All paths presented in this entry are relative to project's main directory which is obtained by cloning the repository.

Please note that all tests written for the application should be contained within com.blstream.myguide.test package (or in a child package).

Eclipse

  • assuming you have ADT plugin installed and configured
  • tested on Juno
  • stronly recommending creating a new, empty workspace

This project comes with preconfigured Eclipse project which should be imported with the following steps:

  1. Enter Eclipse
  2. From menu bar select File -> Import
  3. In the appeared window, from Android group, choose Existing Android Code Into Workspace and click Next
  4. Select project's root directory. You should see several entries including MyGuide and MyGuideTests, make sure to import them all.
  5. Press Finish

Now you should have a fully working Eclipse projects integrated with your workspace. Should any errors occur, clean all the projects and restart your IDE.

Running tests with Eclipse is quite simple: right-click on MyGuideTests and select Run As -> Android JUnit Test.

Before you start coding please make sure you have set a proper Code Convention for the project. It is defined in /android-formatting.xml. To use it, follow these steps:

  1. Enter Eclipse
  2. Right click on MyGuide project and select Properties -> Java Code Style -> Formatter
  3. Check Enable project specific settings box
  4. Press Import button, navigate to project's root directory and select android-formatting.xml file
  5. Press Apply button
  6. Repeat steps 2 - 3 for MyGuideTests project
  7. From Active profile combobox choose just imported profile (should be named Android)

Android Studio

  • tested on Android Studio 0.4.2

This project comes with preconfigured Android Studio project. In order to use it follow these steps:

  1. Enter Android Studio. You should see a Welcome screen if not, you can be working on an other project so close it.
  2. Select Open Project option.
  3. Navigate to the project's main directory location. It should have a nice icon corresponding to the Android Studio. Press Ok.

Tests can be run with the following steps:

  1. In the Project window navigate to /tests/src/
  2. Click it with your mouse's right button and select Run -> All tests.

Before you start coding please make sure you have set a proper Code Convention for the project. TODO