Package org.fusesource.ide.branding.wizards.NewCamelTestWizardPageTwo

Examples of org.fusesource.ide.branding.wizards.NewCamelTestWizardPageTwo.EndpointMaps


    }
    buffer.append("void ");//$NON-NLS-1$
    buffer.append(testName);
    buffer.append("() throws Exception");//$NON-NLS-1$

    EndpointMaps endpointMaps = fPage2.getCheckedEndpointMaps();

    appendTestMethodBody(buffer, type.getCompilationUnit(), endpointMaps);
    type.createMethod(buffer.toString(), null, false, null);

    // now lets create the test fields

    // TODO configure how many bodies to use
    if (endpointMaps.getInputEndpoint() != null) {
      type.createField(delimiter +
          "// TODO Create test message bodies that work for the route(s) being tested" + delimiter +
          "// Expected message bodies" + delimiter
          + "protected Object[] expectedBodies = {\"<something id='1'>expectedBody1</something>\","
          + delimiter + "    \"<something id='2'>expectedBody2</something>\" };", null, false, null);
    }

    Map<String, String> inputEndpoints = endpointMaps.getInputEndpoints();
    Map<String, String> outputEndpoints = endpointMaps.getOutputEndpoints();

    int idx = 0;
    for (Map.Entry<String, String> entry : inputEndpoints.entrySet()) {
      appendProducerTemplateField(type, entry.getKey(), entry.getValue(), idx++, endpointMaps);
    }
View Full Code Here

TOP

Related Classes of org.fusesource.ide.branding.wizards.NewCamelTestWizardPageTwo.EndpointMaps

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.