Examples of Apple


Examples of org.mule.tck.testmodels.fruit.Apple

    }

    public void testLookUpbyType() throws Exception
    {
        Apple apple = new Apple();
        muleContext.getRegistry().registerObject("apple", apple);
        MuleMessage message = new DefaultMuleMessage("foo", muleContext);
        RegistryExpressionEvaluator eval = new RegistryExpressionEvaluator();
        eval.setMuleContext(muleContext);
        Object o = eval.evaluate("type:org.mule.tck.testmodels.fruit.Apple", message);
View Full Code Here

Examples of org.mule.tck.testmodels.fruit.Apple

    {
        //Though the data is simple we are testing two things -
        //1) Mixins are recognised by the Transformer resolver
        //2) that we successfully marshal and marshal an object that is not annotated directly
        MuleMessage message = new DefaultMuleMessage(APPLE_JSON, muleContext);
        Apple apple = (Apple) message.getPayload(DataTypeFactory.create(Apple.class));
        assertNotNull(apple);
        assertFalse(apple.isWashed());
        assertTrue(apple.isBitten());

        message = new DefaultMuleMessage(apple, muleContext);
        String json = message.getPayload(DataType.STRING_DATA_TYPE);
        assertNotNull(json);
        JsonData data = new JsonData(json);
View Full Code Here

Examples of org.mule.tck.testmodels.fruit.Apple

        ExpressionTransformer transformer = (ExpressionTransformer) muleContext.getRegistry().lookupTransformer("testTransformer");
        Map<String, Object> props = new HashMap<String, Object>();
        props.put("foo", "moo");
        props.put("bar", "mar");

        MuleMessage message = new DefaultMuleMessage(new FruitBowl(new Apple(), new Banana()), props, muleContext);

        Object result = transformer.transform(message);
        assertNotNull(result);
        assertTrue(result.getClass().isArray());
        Object o1 = ((Object[]) result)[0];
View Full Code Here

Examples of org.mule.tck.testmodels.fruit.Apple

    {
        ExpressionTransformer transformer = (ExpressionTransformer) muleContext.getRegistry().lookupTransformer("testTransformer");
        Map<String, Object> props = new HashMap<String, Object>();
        props.put("foo", "moo");

        MuleMessage message = new DefaultMuleMessage(new FruitBowl(new Apple(), new Banana()), props, muleContext);

        Object result = transformer.transform(message);
        assertNotNull(result);
        assertTrue(result.getClass().isArray());
        Object o1 = ((Object[]) result)[0];
View Full Code Here

Examples of org.mule.tck.testmodels.fruit.Apple

    public void testExecutionWithAllMissingOptionalParams() throws Exception
    {
        ExpressionTransformer transformer = (ExpressionTransformer) muleContext.getRegistry().lookupTransformer("testTransformer");

        MuleMessage message = new DefaultMuleMessage(new FruitBowl(new Apple(), new Banana()), muleContext);

        Object result = transformer.transform(message);
        assertNotNull(result);
        assertTrue(result.getClass().isArray());
        Object o1 = ((Object[]) result)[0];
View Full Code Here

Examples of org.sgx.yuigwt.yuitest1.gallery.test.yql.YQLStorageTest1.Apple

  console.contentBox().setX(200);
  this.Y=Y_;
  params1 = YQLParams.create().format("json").diagnostics("true");  
//  createRecord1();

  Apple a1 = new Apple("apple1", "red", 123);
  nativeMethod1(a1, this.Y, this.console);
//  console.log(Y.dump(a1, 10), "", "");
}
View Full Code Here

Examples of tests.jfun.yan.xml.models.Apple

  throws Throwable{
    runTest("test/yan/test_expansion.xml");
    super.yan.getInstance("tests.jfun.yan.xml.models.Apple");
    super.yan.getInstance("tests.jfun.yan.xml.models.Orange");
    super.yan.getInstance("tests.jfun.yan.xml.models.orange");
    final Apple apple = (Apple)super.yan.getInstance("tests.jfun.yan.xml.models.apple");
    final Human human = (Human)yan.getInstance("human");
    assertSame(apple, human.getFruit());
    assertEquals(3, Apple.getInstances());
    assertEquals(3, Orange.getInstances());
   
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.