Fixed
Status Update
Comments
uc...@google.com <uc...@google.com> #2
This time actually attaching the project :)
yb...@google.com <yb...@google.com> #3
Yes, we don't merge assets in libraries now for performance reasons. This is a larger change that I don't think will make it in 3.0
yb...@google.com <yb...@google.com> #4
Could test_config.properties & Robolectric then be updated to accept a set of assetDirs (currently points to a single dir) to workaround this problem? I'll try to find some time to craft a Gradle hack (copying assets) in the meantime as this is a blocker for our migration to AGP 3.0.
yb...@google.com <yb...@google.com>
yb...@google.com <yb...@google.com> #5
Problem is this means that Robolectric tests won't work for libraries using the new build system api.
I wonder how users test library components now, does AGP generate a BuildConfig.class for libraries?
Is it possible to mitigate / defer the performance concerns and just do the merging if includeAndroidResources = true is specified?
If its not going to be supported in 3.0 we'll need to message it on the Robolectric site and provide some kind of alternative.
I wonder how users test library components now, does AGP generate a BuildConfig.class for libraries?
Is it possible to mitigate / defer the performance concerns and just do the merging if includeAndroidResources = true is specified?
If its not going to be supported in 3.0 we'll need to message it on the Robolectric site and provide some kind of alternative.
Description
Version of Gradle Plugin: 3.1.0
Version of Gradle: 4.4
Version of Java: 1.8
OS: MacOS 10.13.3
source of sample:
In sample app three modules:
Application module that has implementation project(':featurelevel1')
Level1 Module that has implementation project(':featurelevel2')
Level2 Module with main launcher activity
All modules have databinding enabled and compiler v2 is enabled
To reproduce crash:
Just compile and start app and then there will be crash:
NPE com.github.nekdenis.featurelevel2.databinding.ActivityLevel2Binding.setUser
This happens because DataBinderMapperImpl does not know about com.github.nekdenis.featurelevel2.DataBinderMapperImpl()
If uncomment this line app will work:
But in this case application module should now about EVERY gradle-module of app that is unacceptable.