[java-identity-provider] branch main updated: Full fix to field init bug, plus unit test.
Scott Cantor
cantor.2 at osu.edu
Mon Sep 28 22:56:17 UTC 2020
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-identity-provider.
View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=82ff5de501b67fd9d5b427033b6b28e114c22d97
The following commit(s) were added to refs/heads/main by this push:
new 82ff5de50 Full fix to field init bug, plus unit test.
82ff5de50 is described below
commit 82ff5de501b67fd9d5b427033b6b28e114c22d97
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Mon Sep 28 18:56:14 2020 -0400
Full fix to field init bug, plus unit test.
---
.../src/main/java/net/shibboleth/idp/module/ModuleContext.java | 1 +
.../src/test/java/net/shibboleth/idp/module/IdPModuleTest.java | 3 +++
2 files changed, 4 insertions(+)
diff --git a/idp-admin-api/src/main/java/net/shibboleth/idp/module/ModuleContext.java b/idp-admin-api/src/main/java/net/shibboleth/idp/module/ModuleContext.java
index 5fb279e64..092877a93 100644
--- a/idp-admin-api/src/main/java/net/shibboleth/idp/module/ModuleContext.java
+++ b/idp-admin-api/src/main/java/net/shibboleth/idp/module/ModuleContext.java
@@ -74,6 +74,7 @@ public final class ModuleContext {
*/
public ModuleContext(@Nonnull final Path home) {
idpHome = Constraint.isNotNull(home, "IdP home path cannot be null");
+ languageRanges = Collections.emptyList();
}
/**
diff --git a/idp-admin-api/src/test/java/net/shibboleth/idp/module/IdPModuleTest.java b/idp-admin-api/src/test/java/net/shibboleth/idp/module/IdPModuleTest.java
index 99f8aa21c..b336f0052 100644
--- a/idp-admin-api/src/test/java/net/shibboleth/idp/module/IdPModuleTest.java
+++ b/idp-admin-api/src/test/java/net/shibboleth/idp/module/IdPModuleTest.java
@@ -157,6 +157,9 @@ public class IdPModuleTest {
RepositorySupport.buildHTTPSResourceURL("java-identity-provider", "idp-admin-api/src/test/resources/net/shibboleth/idp/module/test.vm"));
Assert.assertEquals(resource.getDestination(), Path.of("views/test.vm"));
+ // Test with no ranges.
+ Assert.assertEquals(testModule.getName(context), "Test module");
+
context.setLanguageRanges(LanguageRange.parse("fr, de"));
Assert.assertEquals(testModule.getName(context), "Test module (French)");
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list