use of com.dexels.navajo.expression.api.FunctionInterface in project navajo by Dexels.
the class StandardFunctionsTest method testGetCents.
@Test
public void testGetCents() {
FunctionInterface fi = fff.getInstance(cl, "GetCents");
fi.reset();
fi.setInMessage(createTestNavajo());
fi.insertMoneyOperand(new Money(100.50));
Object o = fi.evaluateWithTypeChecking();
assertNotNull(o);
}
use of com.dexels.navajo.expression.api.FunctionInterface in project navajo by Dexels.
the class StandardFunctionsTest method testFormatStringList.
@Test
public void testFormatStringList() {
FunctionInterface fi = fff.getInstance(cl, "FormatStringList");
fi.reset();
ArrayList<String> list = new ArrayList<String>();
list.add("10");
list.add("20");
fi.insertListOperand(list);
fi.insertStringOperand("&");
Object o = fi.evaluateWithTypeChecking();
assertNotNull(o);
assertEquals("10&20", o.toString());
}
use of com.dexels.navajo.expression.api.FunctionInterface in project navajo by Dexels.
the class StandardFunctionsTest method testStringPadding3.
@Test
public void testStringPadding3() {
FunctionInterface fi = fff.getInstance(cl, "StringPadding");
fi.reset();
fi.insertStringOperand("aap");
fi.insertIntegerOperand(Integer.valueOf(10));
Object o = fi.evaluateWithTypeChecking();
assertNotNull(o);
assertEquals(String.class, o.getClass());
assertEquals("aap ", o.toString());
}
use of com.dexels.navajo.expression.api.FunctionInterface in project navajo by Dexels.
the class StandardFunctionsTest method testGetPropertySubType.
@Test
public void testGetPropertySubType() {
FunctionInterface fi = fff.getInstance(cl, "GetPropertySubType");
fi.reset();
fi.setInMessage(createTestNavajo());
fi.insertStringOperand("/Single/Selectie");
fi.insertStringOperand("testsub");
Object o = fi.evaluateWithTypeChecking();
assertNull(o);
}
use of com.dexels.navajo.expression.api.FunctionInterface in project navajo by Dexels.
the class StandardFunctionsTest method testUnicode.
@Test
public void testUnicode() {
FunctionInterface fi = fff.getInstance(cl, "Unicode");
fi.reset();
fi.insertStringOperand("10");
Object o = fi.evaluateWithTypeChecking();
assertNotNull(o);
}
Aggregations