*/
public class BeanMapExpressionEvaluatorTest extends TestCase {
public void test() throws IOException, SAXException {
Smooks smooks;
ExecutionContext execContext;
Map<String, Object> bean = new HashMap<String, Object>();
DOMVisitor.visited = false;
smooks = new Smooks(getClass().getResourceAsStream("smooks-config-01.xml"));
execContext = smooks.createExecutionContext();
execContext.getBeanContext().addBean("aBean", bean, null);
bean.put("a", "hello");
smooks.filterSource(execContext, new StreamSource(new StringReader("<a/>")), null);
assertTrue(DOMVisitor.visited);
DOMVisitor.visited = false;
smooks = new Smooks(getClass().getResourceAsStream("smooks-config-01.xml"));
execContext = smooks.createExecutionContext();
execContext.getBeanContext().addBean("aBean", bean, null);
bean.put("a", "goodbye");
smooks.filterSource(execContext, new StreamSource(new StringReader("<a/>")), null);
assertFalse(DOMVisitor.visited);
}