Search in sources :

Example 1 with TestInterface

use of org.mvel2.tests.core.res.TestInterface in project mvel by mikebrock.

the class AbstractTest method createTestMap.

protected static Map createTestMap() {
    Map map = new HashMap();
    map.put("foo", new Foo());
    map.put("a", null);
    map.put("b", null);
    map.put("c", "cat");
    map.put("BWAH", "");
    map.put("misc", new MiscTestClass());
    map.put("pi", "3.14");
    map.put("hour", 60);
    map.put("zero", 0);
    map.put("array", new String[] { "", "blip" });
    map.put("order", new Order());
    map.put("$id", 20);
    map.put("five", 5);
    map.put("testImpl", new TestInterface() {

        public String getName() {
            return "FOOBAR!";
        }

        public boolean isFoo() {
            return true;
        }
    });
    map.put("derived", new DerivedClass());
    map.put("ipaddr", "10.1.1.2");
    map.put("dt1", new Date(currentTimeMillis() - 100000));
    map.put("dt2", new Date(currentTimeMillis()));
    return map;
}
Also used : Foo(org.mvel2.tests.core.res.Foo) TestInterface(org.mvel2.tests.core.res.TestInterface) DerivedClass(org.mvel2.tests.core.res.DerivedClass)

Aggregations

DerivedClass (org.mvel2.tests.core.res.DerivedClass)1 Foo (org.mvel2.tests.core.res.Foo)1 TestInterface (org.mvel2.tests.core.res.TestInterface)1