Add tests for JavaTypeSubstitutor