@Test
public void testComplexServiceClassEmitTypes() {

    ServiceModel model = serviceClassParser.parseServiceClass(TestComplexServiceClass.class, settings);
    ServiceEmitter serviceEmitter = new ServiceEmitter(model, settings, writer);
    serviceEmitter.emitTypescriptTypes(settings, Lists.newArrayList());
    writer.close();
    String expectedOutput = "" +
 +
 export interface DataObject {\n" +
     y: MyObject;\n" +
 }\n" +
 +
 export interface GenericObject<T> {\n" +
     y: T;\n" +
 }\n" +
 +
 export interface ImmutablesObject {\n" +
     y: string;\n" +
 }\n" +
 +
 export interface MyObject {\n" +
     y: MyObject;\n" +
 }\n\n\n    // Added by 'EnumConstantsExtension' extension\n" +
    assertEquals(expectedOutput, new String(stream.toByteArray()));
}