问题
I have project with two modules: library and example. Everything working fine since I would like to use data binding in my library module.
When I try to use class in example module with databinding usage app crashes with:
Caused by: java.lang.NoClassDefFoundError: Failed resolution of:
Lcom/app/test/databinding/TextItemBinding;
I'm using gradle 2.1.2
and also tested with 2.2.0-beta2
.
Both modules has import for:
dataBinding {
enabled true
}
When I move my code of DataBinding
to single module project code is working correctly.
Has anyone had similar problem?
回答1:
Found resolution, I had:
testCoverageEnabled true
in debug
section which was showing this error.
来源:https://stackoverflow.com/questions/39200465/data-binding-in-library-module