It appears that JEXL is performing the concatenation of 'some text' and output before the ternary operator ?: is performed. With your original expression, 'some text ' + output?'true':'false', I get an output of true. I'm not entirely sure why 'some text ' + false yields true, but there must...
7/2 expression will evaluate to int result and so it is failing to cast Integer to Float, if you want it to be resulting in float you need to change expression to 7 / 2.0F