You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bval.apache.org by ta...@apache.org on 2023/02/08 13:19:50 UTC
[bval] branch master updated: fixed tests
This is an automated email from the ASF dual-hosted git repository.
tandraschko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bval.git
The following commit(s) were added to refs/heads/master by this push:
new 606276f fixed tests
606276f is described below
commit 606276f25182094ab67b2f182e0beabb1b0bad80
Author: Thomas Andraschko <ta...@apache.org>
AuthorDate: Wed Feb 8 14:19:36 2023 +0100
fixed tests
---
.../java/org/apache/bval/jsr/DefaultMessageInterpolatorTest.java | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/bval-jsr/src/test/java/org/apache/bval/jsr/DefaultMessageInterpolatorTest.java b/bval-jsr/src/test/java/org/apache/bval/jsr/DefaultMessageInterpolatorTest.java
index 1ce9a25..20ecb37 100644
--- a/bval-jsr/src/test/java/org/apache/bval/jsr/DefaultMessageInterpolatorTest.java
+++ b/bval-jsr/src/test/java/org/apache/bval/jsr/DefaultMessageInterpolatorTest.java
@@ -65,7 +65,6 @@ public class DefaultMessageInterpolatorTest {
return Arrays.asList(new Object[] { "default", null },
new Object[] { "ri", "org.glassfish.expressly.ExpressionFactoryImpl" },
new Object[] { "tomcat", "org.apache.el.ExpressionFactoryImpl" },
- // new Object[] { "juel", "de.odysseus.el.ExpressionFactoryImpl" },
new Object[] { "invalid", "java.lang.String" });
}
@@ -105,10 +104,7 @@ public class DefaultMessageInterpolatorTest {
elFactoryClass = Class.forName(elFactory);
System.setProperty(ExpressionFactory.class.getName(), elFactory);
}
- // todo clarify why we would get a different instance while the service loader will always pick up the first
- // in the classpath. As we have 3 implementations, we will always get the same one
- assertTrue(elFactoryClass.isInstance(ExpressionFactory.newInstance()));
- elAvailable = true;
+ elAvailable = ExpressionFactory.class.isAssignableFrom(elFactoryClass);
} catch (Exception e) {
elAvailable = false;
}
@@ -242,7 +238,7 @@ public class DefaultMessageInterpolatorTest {
@Test
public void testELEscapingTomcatJuel() {
assumeTrue(elAvailable);
- assumeThat(elImpl, anyOf(equalTo("tomcat"), equalTo("juel")));
+ assumeThat(elImpl, anyOf(equalTo("tomcat")));
// not so much a test as an illustration that the specified EL implementations are seemingly confused by leading
// backslashes and treats the whole expression as literal. We could skip any literal text before the first