blob: 43236acd9d7225f269c6e48a04023915adb9af74 [file] [log] [blame]
Setting up an Android project for robolectric: [warning: massively wrong]
mkdir code aidls
mv src gen code
find all *.aidl under code and move under aidls
create IntelliJ project. It should make a Code module (as a plain old java module) and Aidls module (with an Android Facet) for you.
git submodule add git@github.com:xtremelabs/robolectric.git ./robolectric
Go to Module Setup
Select Code module -> Dependencies
Add -> Global Library... -> Android x.x
Select (main module) -> Android facet
Select (*) Generate Java files under other source root: [ .../code/gen ]
Select (main module) -> Dependencies
Add -> Module dependency -> Code
Add -> Module dependency -> Aidls
Create new module -> use existing iml with robolectric/robolectric.iml.
Select Code module -> Dependencies
Add -> Module dependency -> robolectric
Change scope from Compile to Test
OK
If you get an error complaining that (main module) includes code/gen, remove that from its Sources list.