I'm not really sure what this test is testing?
It was originally written by Dimitris so you might want to ping him.
Two different threads doing a commit on the same transaction
is pretty unusual (it won't happen normally in JBoss)
and will only happen if somebody is playing with the thread association.