see https://github.com/junit-team/junit/wiki/Categories this is only available for junit 4 tests and not for junit 3 suite style tests. A test can be annotated with @Category(NeedGuiTests.class) and it will not be executed in headless mode Also remove the AllTests#suite implementation as it's not compatible with junit4 tests
PR https://github.com/apache/jmeter/pull/107
Date: Thu Feb 4 21:11:13 2016 New Revision: 1728555 URL: http://svn.apache.org/viewvc?rev=1728555&view=rev Log: Bug 58967 : use junit categories to exclude tests that need a gui #resolve #107 Bugzilla Id: 58967 Added: jmeter/trunk/test/src/org/apache/jmeter/junit/categories/ jmeter/trunk/test/src/org/apache/jmeter/junit/categories/ExcludeCategoryFilter.java (with props) jmeter/trunk/test/src/org/apache/jmeter/junit/categories/NeedGuiTests.java (with props) Modified: jmeter/trunk/test/src/org/apache/jmeter/control/TestOnceOnlyController.java jmeter/trunk/test/src/org/apache/jmeter/gui/util/TestMenuFactory.java jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java jmeter/trunk/test/src/org/apache/jmeter/protocol/http/control/gui/TestHttpTestSampleGui.java jmeter/trunk/test/src/org/apache/jmeter/protocol/http/sampler/PackageTest.java jmeter/trunk/test/src/org/apache/jorphan/test/AllTests.java jmeter/trunk/xdocs/changes.xml
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/3819