Good idea. While we are on this subject, I have noticed that tests-clustering is taking a while to run becuase of number of tests included.
Sometimes I find that I only need to run one configuration set, e.g., don't care about UDP, BR, and repl mode, just for development testing purpose. What will be the best way to do this without long waiting? :-)
I should just refactor the tests-clustering target a bit so it calls multiple sub-targets for each of the main sets. Then you could just call the sub-target you want.
It would be better to have the non-http tests in a separate sub-target from the default http ones too, but right now they share the same server start/stop cycle. Making separate sub-targets would add yet another start/stop cycle.
If anyone can add a "one-test-clustering" target, they'll be my friend for life :)
I spent a few hours trying to do that once, but hit a roadblock and gave up.
I've added a 'one-cluster-test' target. It took 5 mins; no idea why I had trouble before.
build -Dtest=org/jboss/tests/cluster/partition/test/* one-cluster-test
It takes whatever you set the 'test' system property to and makes an ant patternset out of it. Then starts the 2 servers in the standard "all" config (UDP, REPL_ASYNC, default BR setting for the branch) and executes all the tests in the patternset.
The name 'one-cluster-test' is inaccurate, since it will run as many tests as your patternset includes.
No ability for other configs (field, REPL-SYNC, non-default-BR) at this point.
Ben, when I get some cycles I'll do the bit you mentioned about easily running all the field tests, etc.
Added the ability to run single tests with other transports than UDP.
This works differently in Branch_4_0 than HEAD, due to differences in the way JGroups is configured when the multiplexer is used.
Same as described above, but use the "one-cluster-test-tcp" target instead of "one-cluster-test". No option to use TCP_NIO.
build -Dtest=org/jboss/tests/cluster/partition/test/* -Djboss-junit-configuration=tcp one-cluster-test
where the value of jboss-junit-configuration is one of the different stacks available in multiplexer-stacks.xml, i.e.
At this point it isn't possible to use udp-sync, tcp-sync or tcp_nio-sync.
If the property isn't set, the default "udp" is used.