Search code examples
intellij-ideagradlejunitintellij-15infinitest

How does one enable Infinitest on a gradle project in IntelliJ IDEA 15?


According to the Infinitest User Guide, after installing the Infinitest plugin in IntelliJ IDEA, you're supposed to be able to right click your project and "choose facet, add Infinitest". However, there is no "facet" option in my project's context menu; I presume it may have to do with the fact that my project is a gradle project, though it does have the .idea project folder as well.

Other specifics about my project (that I don't think are related but could be possibly):

  • it is a multi-module gradle project, with one root project and 4 modules
  • it also has the Scala nature and scala gradle plugin.
  • It has both Junit4 and ScalaTest tests.
  • I'm using Intellij IDEA version 15

Solution

  • To add a facet, you have to go in the module settings (⌘ ↓ on OSX, or "Open Module Settings" in the contextual menu).

    In there, under project settings there is a "Facet" entry, in which you can add an Infinitest facet.

    After that it will appear as a tab at the bottom of the UI.

    cf. the IntelliJ documentation.