### Question:
MVELExtension implements ExpressionLanguageExtension { @Override public <T> Predicate<T> createPredicate(Query<T> query) { return new ExecutableStatementPredicate(query); }  @Override boolean supports(Query<T> query); @Override Predicate<T> createPredicate(Query<T> query);  }### Answer:
@Test void ensurePredicateWorksForSuccessfulModuleCase() { val el = resolve(); val ctx = new Context<>(module, null); given(coordinate.getName()).willReturn("test"); given(module.getCoordinate()).willReturn(coordinate); val query = new Query<>("context.module.coordinate.name == 'test'", "mvel", ctx); assertTrue(el.createPredicate(query).test(module), "module name must be test"); }
@Test void ensurePredicateWorksForUnsuccessfulModuleCase() { val el = resolve(); val ctx = new Context<>(module, null); given(coordinate.getName()).willReturn("frapper"); val query = new Query<>("value.name == 'test'", "mvel", ctx); assertFalse(el.createPredicate(query).test(coordinate), "module name must not be test"); }