views:

46

answers:

2

Hello!

I have like trillion test packages with bazillion tests and I want to run just some of packages. Now I must run whole project (some tests takes long to complete) or I need to run every single file manually. How is possible to run just some packages in NetBeans ? I can't find this option ...

+1  A: 

It's probably not what you want, but the NetBeans help topic, Running a JUnit Test, says:

If you want to run a subset of the project's tests or run the tests in a specific order, you can create test suites that specify the tests to run as part of that suite. After creating a test suite you run the suite in the same way you run a single test class.

Creating a test suite is covered in the topic Creating a JUnit Test.

trashgod
yep I knew that only solution so far is writing suite, but I am actually pretty surprised (or I don't understand how is that not possible) that such an great IDE doesn't offer this feature :/
Xorty
@Xorty: Yes, although you can run individual tests in NetBeans, I don't see any other way to run a subset. It is a little easier to run selected tests in Eclipse.
trashgod
@trashgod - I use tons of Maven and I am not giving up NetBeans there ... (nothing again Eclipse it's brilliant)
Xorty
A: 

If you use JUnit 4 then try ClasspathSuite and its regex filters.

grigory