java.lang.IllegalArgumentException: Not a file or directory: xxxxxx\.idea\modules\src\test\resources\features


I'm getting the above compile error in my Scala test project and just cannot resolve.

My project structure is:



-project (sources root)

-src -> main -> scala

      -> test -> resources -> features -> firstFeature.feature

                  -> scala -> stepdefs (package) -> RunCucumber.scala


My RunCucumber class :-

package stepdefs

import cucumber.api.junit.Cucumber
import cucumber.api.CucumberOptions
import org.junit.runner.RunWith

features = Array("src/test/resources/features"),
glue = Array("stepdefs"),
format = Array("pretty", "html:target/cucumber-report"),
tags = Array("@wip")
class RunCucumber {

I dont know why its trying to look in the .idea directory path to do the compile or where to change the configuration to resolve this?

When i created the scala project there was no resources directory in test, i had to create it (along with the features directory).

The error occurs when i run RunCucumber

Any advice please for a newbie? I understand the issue, just dont know the cause or how to resolve.




I've created a ticket for a further processing. Is it possible to provide the project or at least some of the following information as attachment to the ticket?

Screenshot of

- project view. If it's higher than one screen - show the place where problematic file locates.

- project structure -> modules -> Sources 

- project structure -> modules -> Paths 

- project structure -> Project

IDEA logs after the error appears (Help menu -> Collect and Show Logs in Finder) 



Hi Anton - thanks for taking the time to reply.

I'm trying to complete the Scala SBT Cucumber tutorial that is here:

I've downloaded the latest versions of IntelliJ, JDK9 etc.

When i follow the instructions, no resources directory is created :

I create the resources directory along with features etc but when i run RunCucumber, it throws the error and expects the directory path to be in the .idea path.

I've managed to set up Java Selenium and Scala projects okay but seem to be having a real problem with this.

Any help or pointers much appreciated (I've added the screenshots as an attachment to the ticket)





Got it. Thanks! We'll take a look.


Please sign in to leave a comment.