It seems really odd to mock and test calls to this class. What project are you using it in? I would think you'd test calls at a higher level (e.g., to methods which then invoke this class) or at a lower level (e.g., the generated Java string/output).