[java-identity-provider] branch master updated: IDP-1349 - Enable two disabled tests

Tom Zeller tzeller at dragonacea.biz
Mon Nov 4 16:17:16 EST 2019


This is an automated email from the git hooks/post-receive script.

tzeller pushed a commit to branch master
in repository java-identity-provider.

View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=aebc029e1fef9faa370111341159a4a9fd924494

The following commit(s) were added to refs/heads/master by this push:
       new  aebc029   IDP-1349 - Enable two disabled tests
aebc029 is described below

commit aebc029e1fef9faa370111341159a4a9fd924494
Author: Tom Zeller <tzeller at dragonacea.biz>
AuthorDate: Mon Nov 4 15:16:07 2019 -0600

    IDP-1349 - Enable two disabled tests
    
    Added assert to make sure /opt/shibboleth-idp.conf/idp.properties does
    not exist when running test.
    
    https://issues.shibboleth.net/jira/browse/IDP-1349
---
 .../IdPPropertiesApplicationContextInitializerTest.java     | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/idp-conf/src/test/java/net/shibboleth/idp/test/spring/IdPPropertiesApplicationContextInitializerTest.java b/idp-conf/src/test/java/net/shibboleth/idp/test/spring/IdPPropertiesApplicationContextInitializerTest.java
index 8ae2333..5737616 100644
--- a/idp-conf/src/test/java/net/shibboleth/idp/test/spring/IdPPropertiesApplicationContextInitializerTest.java
+++ b/idp-conf/src/test/java/net/shibboleth/idp/test/spring/IdPPropertiesApplicationContextInitializerTest.java
@@ -17,6 +17,9 @@
 
 package net.shibboleth.idp.test.spring;
 
+import java.nio.file.Files;
+import java.nio.file.Paths;
+
 import javax.servlet.ServletContextEvent;
 
 import org.springframework.beans.factory.BeanDefinitionStoreException;
@@ -56,14 +59,16 @@ public class IdPPropertiesApplicationContextInitializerTest {
         WebApplicationContextUtils.getRequiredWebApplicationContext(sc);
     }
 
-    // TODO: test isn't working
-    @Test(enabled=false, expectedExceptions = ConstraintViolationException.class) public void testNotFound() {
+    @Test(expectedExceptions = ConstraintViolationException.class) public void testNotFound() {
+        Assert.assertFalse(Files.exists(Paths.get("/opt", "shibboleth-idp", "conf", "idp.properties")),
+                "File /opt/shibboleth-idp/conf/idp.properties should not exist");
         listener.contextInitialized(new ServletContextEvent(sc));
         WebApplicationContextUtils.getRequiredWebApplicationContext(sc);
     }
 
-    // TODO: test isn't working
-    @Test(enabled=false, expectedExceptions = {BeanDefinitionStoreException.class}) public void testNotFoundFalseFailFast() {
+    @Test(expectedExceptions = {BeanDefinitionStoreException.class}) public void testNotFoundFalseFailFast() {
+        Assert.assertFalse(Files.exists(Paths.get("/opt", "shibboleth-idp", "conf", "idp.properties")),
+                "File /opt/shibboleth-idp/conf/idp.properties should not exist");
         sc.addInitParameter("idp.initializer.failFast", "false");
         listener.contextInitialized(new ServletContextEvent(sc));
         WebApplicationContextUtils.getRequiredWebApplicationContext(sc);

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list