Compiling Espresso these days

165 views
Skip to first unread message

John Lombardo

unread,
Nov 27, 2015, 4:46:17 PM11/27/15
to Android Testing Support Library
I've been working on compiling Espresso for awhile now, and so far no luck. What I've tried so far:

  1. Directly adding the Espresso sources to my project. I've almost gotten this to work by adding lots of other source that espresso relies on, but there's one file I can't find at all: `DaggerBaseLayerComponent`. It's referenced by GraphHolder.java. I literally can't find this anywhere -- in the Android sources or on the internet.

  2. By compiling the Android sources. To do this, I've downloaded the master branch and modified my repo manifest to add the platform-frameworks-testing package back in. This also fails to build. I don't think I can use the master branch, I probably need to go back to something else, but I'm not sure what.
So my bottom line question is this: How do I build espresso from source?


John Lombardo

unread,
Nov 27, 2015, 4:56:58 PM11/27/15
to Android Testing Support Library
This link shows that the source was explicitly removed from the Android sources, but I can't find any explanation as to where it went or how it should be compiled now.

Stephan Linzner

unread,
Nov 27, 2015, 5:59:18 PM11/27/15
to John Lombardo, Android Testing Support Library
Hey John,

just follow our instructions on the ATSL page on how to build/test from source and contribute to the project.

Thanks,
Stephan

On 27 November 2015 at 13:56, John Lombardo <john.l...@gmail.com> wrote:
This link shows that the source was explicitly removed from the Android sources, but I can't find any explanation as to where it went or how it should be compiled now.

--
You received this message because you are subscribed to the Google Groups "Android Testing Support Library" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-testing-suppo...@googlegroups.com.
To post to this group, send email to android-testing...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-testing-support-library/268eef87-b612-42da-a5ad-b07e94cd5d12%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Senior Developer Platforms Engineer, Google Inc. | slin...@google.com | +Stephan Linzner | @onlythoughtwork 

slinzner

unread,
Nov 27, 2015, 5:59:53 PM11/27/15
to Android Testing Support Library
Hey John,

just follow our instructions on the ATSL page on how to build/test from source and contribute to the project.

Thanks,
Stephan

John Lombardo

unread,
Nov 27, 2015, 6:52:38 PM11/27/15
to Android Testing Support Library
I thought I had looked everywhere, but apparently I did not. Thank you!

John Lombardo

unread,
Nov 28, 2015, 1:46:52 PM11/28/15
to Android Testing Support Library
In case anyone else finds this thread -- these are the commands I had to execute after following the instructions Steve mentioned:
  1. Create a symlink named version.gradle to frameworks/testing/version.gradle
    ln -s frameworks/testing/version.gradle version.gradle

  2. Create a symlink to your copy of adb and friends. This assumes that adb is on your path.
    (BIN=out/host/darwin-x86 ; mkdir -p $BIN ; cd $BIN ; ln -s $(dirname $(which adb)) bin)
You can now run the `./gradlew connectedAndroidTest` command.

BTW, since it's not entirely obvious -- if you want to create distributable JARs the command is
./gradlew clean createReleaseJarWithDeps

On Friday, November 27, 2015 at 2:59:53 PM UTC-8, slinzner wrote:
Reply all
Reply to author
Forward
0 new messages