unit test for Semaphore

Can you have a look at TestThread in StressTest support. It automatically places a try/catch(throwable) around the running method and you can do e.g.

thread.assertJoined()// where you can check for no exceptions for example.

You can add this TestThread to the test support package so that in the future we can use it at other placed. 

The problem with the current approach is that you have no clue if the call the semaphore.acquire has failed (only a stacktrace in the log.. nobody is going to see that in the future).