use of com.nextdoor.bender.operation.substitution.ztatic.StaticSubstitution in project bender by Nextdoor.
the class StaticSubstitutionTest method testStaticField.
@Test
public void testStaticField() throws FieldNotFoundException {
ArrayList<Substitution> substitutions = new ArrayList<Substitution>();
substitutions.add(new StaticSubstitution("foo", "1234", true));
DummpyMapEvent devent = new DummpyMapEvent();
InternalEvent ievent = new InternalEvent("", null, 0);
ievent.setEventObj(devent);
SubstitutionOperation op = new SubstitutionOperation(substitutions);
op.perform(ievent);
assertEquals("1234", devent.getField("foo"));
}
Aggregations