24 May 2017

How run test multiple times in IntelliJ IDEA ?

Solution works for :  IntelliJ IDEA 2016.3 and later, but I don't know when it was added.

Ages ago, IntelliJ IDEA added really cool feature to repeat test.
If for whatever reason you need repeat test x amount of times then follow these steps:

  1. Run test (tests) first.
  2. Go to Edit Configuration
  3. In configuration tab, in top right corner, you can specify repat test

Apply and run it :)

Small warning!  For very large amount of test IntelliJ IDEA start works very very slowly. I usually I don't have problem with running more than around 65535  and more tests,but it depends on tests amount and size of the project :).