BISERVER-7873 - Potential bug: use of String#toUpperCase is unsafe

fix anf JUnit
Merge pull request #1154 from apratkin/BISERVER-7873

BISERVER-7873 - Potential bug: use of String#toUpperCase is unsafe