Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to execute a single unit test case using activator?

we are using play framework and activator as a build tool,we have many unit test cases written in out project,can you please tell me how to run single unit test case using activator ? i tried running this command in command line

activator test-only SampleNodeServiceImplTest.

but this command is running all the test cases in the project. but i want to run only one specific unit test case.

like image 791
user3962745 Avatar asked Aug 28 '15 09:08

user3962745


2 Answers

It looks like you have to enclose the argument to activator in quotes, that is, activator "test-only package.SampleNodeServiceImplTest" should work (see https://groups.google.com/forum/#!topic/play-framework/xGDhQSz5cTs).

like image 138
Jan Christiansen Avatar answered Dec 16 '22 06:12

Jan Christiansen


Instead of test-only you can also use testOnly as follow

activator "testOnly package.SampleNodeServiceImplTest".

Giving the the full package path also very important

like image 31
Hiran Avatar answered Dec 16 '22 06:12

Hiran