By default, when a Jenkins runs your tests (via ANT) and tests fail, your build will not be marked as "Failed" but as "Unstable". If this is not what you want -- if you want failed tests to cause a build failure -- you need only make a small modification to your ANT build.
This works because the failure property will only be set if there are failures. If no failures occur, the property remains unset.
The fail directive's "if" test will return true only if the property exists -- it does not matter whether it's a boolean, whether it's true, etc. I simply need exist. Consequently, fail will only run if the failureproperty is set due to failed tests