I would be cautious of implementing a magic string conversion process using any DevTest classes and methods below the testExec.parseInState( <dataToParse> ) method. This is the standard wrapper that exposes the magic sting parsing logic.
CA reserves the right to change DevTest from one release to the next. In the long term, hacking into any parsing logic below this wrapper method could be detrimental to the code you are building and the application using it.