MultiProject Build failure

I have a project which was not building using Gradle (test case failures) while the same built under Maven.

On debugging, the project had a dependency on ‘org.easymock’ (version: 3.1). Further googling I got to know that 3.1 version of easymock does not require ‘org.objenesis’ and ‘cglib’ dependency to be present.

On removing those (objenesis & cglib) dependencies, the project is building perfectly in Gradle.

However the problem is, if I build the same project as part of Multi Project build, it fails and the log file has the same error as it was earlier with objenesis and cglib present.

Please let me know any workaround.

Regards

Would you show us your project structure and build scripts?

I have a root project and >50 projects in level 1.

The project I mentioned as failing in Multi Project Build is in Level 1 and builds properly when built individually.

The build files contain dependencies required to compile + repository to access and sourceSets specified… Nothing more.

All the dependency are in terms of jars which is always present in the Maven local repo.
While building this project there is no dependency to build other projects, it just downloads the jars from local repo.