You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jspwiki.apache.org by ju...@apache.org on 2020/12/08 22:13:15 UTC
[jspwiki] branch master updated (9c313bf -> 104ee2d)
This is an automated email from the ASF dual-hosted git repository.
juanpablo pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/jspwiki.git.
from 9c313bf 2.11.0-M8-git-06
new fd3524e small refactor on test to not use deprecated code
new 104ee2d prepare 2.11.0.M8 release
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../src/main/java/org/apache/wiki/api/Release.java | 2 +-
.../org/apache/wiki/auth/AuthorizationManagerTest.java | 16 +++++++++-------
2 files changed, 10 insertions(+), 8 deletions(-)
[jspwiki] 01/02: small refactor on test to not use deprecated code
Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
juanpablo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jspwiki.git
commit fd3524ed8c142bf75d91beb428f7c0cd18e0b153
Author: juanpablo <ju...@apache.org>
AuthorDate: Tue Dec 8 23:04:18 2020 +0100
small refactor on test to not use deprecated code
---
.../org/apache/wiki/auth/AuthorizationManagerTest.java | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/jspwiki-main/src/test/java/org/apache/wiki/auth/AuthorizationManagerTest.java b/jspwiki-main/src/test/java/org/apache/wiki/auth/AuthorizationManagerTest.java
index 2f86374..cc73b5e 100644
--- a/jspwiki-main/src/test/java/org/apache/wiki/auth/AuthorizationManagerTest.java
+++ b/jspwiki-main/src/test/java/org/apache/wiki/auth/AuthorizationManagerTest.java
@@ -21,11 +21,12 @@ package org.apache.wiki.auth;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.wiki.TestEngine;
import org.apache.wiki.WikiSessionTest;
+import org.apache.wiki.api.core.Attachment;
import org.apache.wiki.api.core.Page;
import org.apache.wiki.api.core.Session;
import org.apache.wiki.api.exceptions.ProviderException;
import org.apache.wiki.api.exceptions.WikiException;
-import org.apache.wiki.attachment.Attachment;
+import org.apache.wiki.api.spi.Wiki;
import org.apache.wiki.attachment.AttachmentManager;
import org.apache.wiki.auth.acl.UnresolvedPrincipal;
import org.apache.wiki.auth.authorize.Group;
@@ -86,7 +87,7 @@ public class AuthorizationManagerTest
// Initialize the test engine
m_engine = new TestEngine( props );
m_auth = m_engine.getManager( AuthorizationManager.class );
- m_groupMgr = m_engine.getGroupManager();
+ m_groupMgr = m_engine.getManager( GroupManager.class );
m_session = WikiSessionTest.adminSession( m_engine );
}
@@ -94,7 +95,8 @@ public class AuthorizationManagerTest
* Tests the default policy. Anonymous users can read, Authenticated can
* edit, etc. Uses the default tests/etc/jspwiki.policy file installed by
* the JRE at startup.
- * @throws Exception
+ *
+ * @throws Exception test failed
*/
@Test
public void testDefaultPermissions() throws Exception
@@ -264,7 +266,7 @@ public class AuthorizationManagerTest
m_engine.saveText( "Test", src );
final File f = m_engine.makeAttachmentFile();
- final Attachment att = new Attachment( m_engine, "Test", "test1.txt" );
+ final Attachment att = Wiki.contents().attachment( m_engine, "Test", "test1.txt" );
att.setAuthor( "FirstPost" );
m_engine.getManager( AttachmentManager.class ).storeAttachment( att, f );
@@ -295,7 +297,7 @@ public class AuthorizationManagerTest
m_engine.saveText( "Test", src );
final File f = m_engine.makeAttachmentFile();
- final Attachment att = new Attachment( m_engine, "Test", "test1.txt" );
+ final Attachment att = Wiki.contents().attachment( m_engine, "Test", "test1.txt" );
att.setAuthor( "FirstPost" );
m_engine.getManager( AttachmentManager.class ).storeAttachment( att, f );
@@ -482,7 +484,7 @@ public class AuthorizationManagerTest
// This should not resolve because there's no built-in role Admin
principal = new WikiPrincipal( "Admin" );
- Assertions.assertFalse( principal.equals( m_auth.resolvePrincipal( "Admin" ) ) );
+ Assertions.assertNotEquals( m_auth.resolvePrincipal( "Admin" ), principal );
}
@Test
@@ -670,7 +672,7 @@ public class AuthorizationManagerTest
// Initialize the test engine
m_engine = new TestEngine( props );
m_auth = m_engine.getManager( AuthorizationManager.class );
- m_groupMgr = m_engine.getGroupManager();
+ m_groupMgr = m_engine.getManager( GroupManager.class );
m_session = WikiSessionTest.adminSession( m_engine );
Session s = WikiSessionTest.anonymousSession( m_engine );
[jspwiki] 02/02: prepare 2.11.0.M8 release
Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
juanpablo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jspwiki.git
commit 104ee2deabf4205eb546c28ac6f52b852a0a39c0
Author: juanpablo <ju...@apache.org>
AuthorDate: Tue Dec 8 23:05:15 2020 +0100
prepare 2.11.0.M8 release
---
jspwiki-api/src/main/java/org/apache/wiki/api/Release.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/jspwiki-api/src/main/java/org/apache/wiki/api/Release.java b/jspwiki-api/src/main/java/org/apache/wiki/api/Release.java
index 337bdba..750b025 100644
--- a/jspwiki-api/src/main/java/org/apache/wiki/api/Release.java
+++ b/jspwiki-api/src/main/java/org/apache/wiki/api/Release.java
@@ -69,7 +69,7 @@ public final class Release {
* <p>
* If the build identifier is empty, it is not added.
*/
- public static final String BUILD = "git-06";
+ public static final String BUILD = "";
/**
* This is the generic version string you should use when printing out the version. It is of