About Issu #660 and contributor

54 views
Skip to first unread message

patrick kolodziejczyk

unread,
Dec 11, 2020, 11:01:20 AM12/11/20
to PowerMock

Hi,

I am a new contributor. I thinks I have identified what is wrong for the Issue #660

I have create an MR #1084 on the principel idea to fix the issu.

But I couldn't setup a proper developement environnemnt to run test. Since I never used gradle. Was kind of lost with it in my eclipse.


Does someone have advice to setup and environnement or could look up the MR or even my analyse of the issue ?

Thanks for your attention.
Truly,
Patrick.

Артур Загретдинов

unread,
Dec 14, 2020, 4:45:56 AM12/14/20
to PowerMock
Hi Patrick, 

Powermock 2 has a really tricky set up as it has two modules: 
  • Mockito 1 - that depends on mockito 1.x and that should be compiled with it and tested with it
  • Mockito 2 - that depends on mocking 2.x/3.x(now). So it should be compiled with mockito 2 in class path. 

Usually either IDEA nor Eclipse cannot understand this structure so you have to manually specify src/test folders for the modules. 

I have configured environment for IDEA. I don’t can it help for you or not. But if you want I can send it to you in attachment. 

In general Eclipse should support import gradle projects. Issue should only for these two modules. You can import one mockito2 as I think it’s time to drop support mockito 1. 

Thanks,
Artur

patrick kolodziejczyk

unread,
Dec 14, 2020, 6:18:20 AM12/14/20
to PowerMock
Hi,

Thanks for the reply,

Being honnest, I don't care about Mockito 1.

I try to have a environnement for Eclipse, but I have a lot of erreur after the gradle import.

In the "Java Build Path Problems" section "A cycle was detected in the build path of project ..."
In gradle when I try to execute a task like "powermockito-mockito2/build/BuildNeeded" or any other project
I have the folowing trace  :

--------------------------------------------------------------------------------------------
Working Directory: C:\tmp\powermock\powermock-core
Gradle User Home: C:\Users\pko\.gradle
Gradle Distribution: Gradle wrapper from target build
Gradle Version: 4.10.2
Java Home: C:\Program Files\Java\jdk1.8.0_201
JVM Arguments: None
Program Arguments: None
Build Scans Enabled: false
Offline Mode Enabled: false
Gradle Tasks: buildNeeded


> Configure project :
  Building version '2.0.10' (value loaded from 'version.properties' file).
Version: 2.0.10
Configuration(s) specified but the install task does not exist in project :powermock-release:powermock-easymock.
Configuration(s) specified but the install task does not exist in project :powermock-release:powermock-mockito2.

FAILURE: Build failed with an exception.

* What went wrong:
Circular dependency between the following tasks:
:powermock-core:buildNeeded
\--- :tests:utils:buildNeeded
     \--- :powermock-core:buildNeeded (*)

(*) - details omitted (listed previously)


* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/4.10.2/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 1s
--------------------------------------------------------------------------------------------

I think they all have the same root cause. Probably something I missed.

Currently, I have only cloned the git depot and imported all in a Eclipse Java EE IDE for Web Developers. Version: 2018-09 .
Then try to build the project.

I will try to do it on IntellyJ

K.

patrick kolodziejczyk

unread,
Dec 14, 2020, 11:00:11 AM12/14/20
to PowerMock
IntellyJ was the way to go.

I updated my MR with a test case, that fail with out my modification. (Kind of checked that by pushing with out it...)

Not sure how the review work is done nor the release process. If you have information about would be nice.

Thanks you.

patrick kolodziejczyk

unread,
Mar 12, 2021, 4:38:23 AM3/12/21
to PowerMock
Any update on that ?
Reply all
Reply to author
Forward
0 new messages