2

I'm running a Junit test and everytime I run it, I wait ~5 minutes for "executing maven goals". After that it starts up application context and runs tests. I know that this same test runs without executing maven goals and a lot faster on other environments.

I tried removing "Build" from configuration... enter image description here

... but then it doesn't update changed files

Here is how it looks in IntelliJ (for my 5 minutes): enter image description here

I suppose Build takes too long in my case, is there any other way to grab the changes before running the test and not wait forever?

Redar
  • 83
  • 10
  • 1
    It looks like you've set IntelliJ IDEA to run some Maven goal before starting the tests. Check it in the [Maven projects tool window](https://i.imgur.com/MzBE13G.png). Also try disabling the [Maven build/run delegation option](https://i.imgur.com/QKGIrbG.png). – CrazyCoder Sep 27 '19 at 20:03
  • Turns out I had "Delegate IDE build/run actions to Maven", disabling it solved the problem. Now it doesn't build entire project for a single change. Thanks @CrazyCoder – Redar Sep 27 '19 at 20:37

1 Answers1

3

Disable the Maven build/run delegation option in File | Settings | Build, Execution, Deployment | Build Tools | Maven | Runner.

CrazyCoder
  • 389,263
  • 172
  • 990
  • 904