Separately running unit and integration tests in IntelliJ

207 views
Skip to first unread message

Chris Toomey

unread,
Aug 6, 2014, 7:50:17 PM8/6/14
to scalate...@googlegroups.com
Hi,

I'm using ScalaTest via the Scala plugin in IntelliJ and am trying to figure out how to separate unit tests from integration tests so that I can run only one or the other at a time.  From the plugin's test configuration panel it looks like my only option is putting unit and integration tests in separate packages, which isn't ideal.  Is there another way I'm overlooking?

Going forward it'd be great if the Scala plugin would allow specification of either a test directory (src/it vs. src/test) or a test name pattern (*UnitTest vs. *IntTest) like the JUnit plugin does.

Chris

John Lonergan

unread,
Aug 8, 2014, 8:19:23 AM8/8/14
to scalate...@googlegroups.com
+1 on this.
We are naming the funsuite classes as *UnitTest and *IntegrationTest and want to run them separately.

They sit in the same package and we want to run by class suffix.

Currently we are working round it by doubling up by tagging individual tests with a UT tag or an IT in adoption to the class naming convention.

Chris Toomey

unread,
Aug 8, 2014, 2:28:15 PM8/8/14
to scalate...@googlegroups.com
Thanks for the heads up about the tag workaround for now, hadn't known about that.

Chris
Reply all
Reply to author
Forward
0 new messages