Modified: 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/RemoveAuthorizablesTest.java
URL: 
http://svn.apache.org/viewvc/incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/RemoveAuthorizablesTest.java?rev=756191&r1=756190&r2=756191&view=diff
==============================================================================
--- 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/RemoveAuthorizablesTest.java
 (original)
+++ 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/RemoveAuthorizablesTest.java
 Thu Mar 19 20:53:24 2009
@@ -39,9 +39,8 @@
                String getUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
userId + ".json";
                assertAuthenticatedHttpStatus(creds, getUrl, 
HttpServletResponse.SC_OK, null); //make sure the profile request returns some 
data
 
-               String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
userId;
+               String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
userId + ".delete.html";
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"deleteAuthorizable"));
                assertAuthenticatedPostStatus(creds, postUrl, 
HttpServletResponse.SC_OK, postParams, null);
                
                getUrl = HTTP_BASE_URL + "/system/userManager/user/" + userId + 
".json";
@@ -56,9 +55,8 @@
                String getUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
groupId + ".json";
                assertAuthenticatedHttpStatus(creds, getUrl, 
HttpServletResponse.SC_OK, null); //make sure the profile request returns some 
data
 
-               String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
groupId;
+               String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
groupId + ".delete.html";
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"deleteAuthorizable"));
                assertAuthenticatedPostStatus(creds, postUrl, 
HttpServletResponse.SC_OK, postParams, null);
                
                getUrl = HTTP_BASE_URL + "/system/userManager/group/" + groupId 
+ ".json";
@@ -77,9 +75,8 @@
                getUrl = HTTP_BASE_URL + "/system/userManager/group/" + groupId 
+ ".json";
                assertAuthenticatedHttpStatus(creds, getUrl, 
HttpServletResponse.SC_OK, null); //make sure the profile request returns some 
data
                
-               String postUrl = HTTP_BASE_URL + "/system/userManager";
+               String postUrl = HTTP_BASE_URL + 
"/system/userManager.delete.html";
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"deleteAuthorizable"));
                postParams.add(new NameValuePair(":applyTo", "group/" + 
groupId));
                postParams.add(new NameValuePair(":applyTo", "user/" + userId));
                assertAuthenticatedPostStatus(creds, postUrl, 
HttpServletResponse.SC_OK, postParams, null);

Modified: 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateGroupTest.java
URL: 
http://svn.apache.org/viewvc/incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateGroupTest.java?rev=756191&r1=756190&r2=756191&view=diff
==============================================================================
--- 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateGroupTest.java
 (original)
+++ 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateGroupTest.java
 Thu Mar 19 20:53:24 2009
@@ -40,9 +40,8 @@
        protected void tearDown() throws Exception {
                if (testGroupId != null) {
                        //remove the test user if it exists.
-                       String postUrl = HTTP_BASE_URL + 
"/system/userManager/group/" + testGroupId;
+                       String postUrl = HTTP_BASE_URL + 
"/system/userManager/group/" + testGroupId + ".delete.html";
                        List<NameValuePair> postParams = new 
ArrayList<NameValuePair>();
-                       postParams.add(new NameValuePair(":operation", 
"deleteAuthorizable"));
                        assertAuthenticatedAdminPostStatus(postUrl, 
HttpServletResponse.SC_OK, postParams, null);
                }
 
@@ -52,10 +51,9 @@
        public void testUpdateGroup() throws IOException, JSONException {
                testGroupId = createTestGroup();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
testGroupId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
testGroupId + ".update.html";
 
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"updateAuthorizable"));
                postParams.add(new NameValuePair("displayName", "My Updated 
Test Group"));
                postParams.add(new NameValuePair("url", 
"http://www.apache.org/updated";));
                
@@ -70,17 +68,15 @@
                JSONObject jsonObj = new JSONObject(json);
                assertEquals("My Updated Test Group", 
jsonObj.getString("displayName"));
                assertEquals("http://www.apache.org/updated";, 
jsonObj.getString("url"));
-               assertFalse(jsonObj.has(":operation"));
        }
        
        public void testUpdateGroupMembers() throws IOException, JSONException {
                testGroupId = createTestGroup();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
testGroupId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/group/" + 
testGroupId + ".update.html";
 
         //TODO: verify this works....
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"updateAuthorizable"));
                postParams.add(new NameValuePair(":member", 
"../user/testUser"));
                postParams.add(new NameValuePair(":mem...@delete", 
"testGroup"));
                

Modified: 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateUserTest.java
URL: 
http://svn.apache.org/viewvc/incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateUserTest.java?rev=756191&r1=756190&r2=756191&view=diff
==============================================================================
--- 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateUserTest.java
 (original)
+++ 
incubator/sling/trunk/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/userManager/UpdateUserTest.java
 Thu Mar 19 20:53:24 2009
@@ -40,9 +40,8 @@
        protected void tearDown() throws Exception {
                if (testUserId != null) {
                        //remove the test user if it exists.
-                       String postUrl = HTTP_BASE_URL + 
"/system/userManager/user/" + testUserId;
+                       String postUrl = HTTP_BASE_URL + 
"/system/userManager/user/" + testUserId + ".delete.html";
                        List<NameValuePair> postParams = new 
ArrayList<NameValuePair>();
-                       postParams.add(new NameValuePair(":operation", 
"updateAuthorizable"));
                        assertAuthenticatedAdminPostStatus(postUrl, 
HttpServletResponse.SC_OK, postParams, null);
                }
 
@@ -52,10 +51,9 @@
        public void testUpdateUser() throws IOException, JSONException {
                testUserId = createTestUser();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId + ".update.html";
 
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"updateAuthorizable"));
                postParams.add(new NameValuePair("displayName", "My Updated 
Test User"));
                postParams.add(new NameValuePair("url", 
"http://www.apache.org/updated";));
                Credentials creds = new UsernamePasswordCredentials(testUserId, 
"testPwd");
@@ -69,16 +67,14 @@
                JSONObject jsonObj = new JSONObject(json);
                assertEquals("My Updated Test User", 
jsonObj.getString("displayName"));
                assertEquals("http://www.apache.org/updated";, 
jsonObj.getString("url"));
-               assertFalse(jsonObj.has(":operation"));
        }
        
        public void testChangeUserPassword() throws IOException {
                testUserId = createTestUser();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId + ".changePassword.html";
 
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"changePassword"));
                postParams.add(new NameValuePair("oldPwd", "testPwd"));
                postParams.add(new NameValuePair("newPwd", "testNewPwd"));
                postParams.add(new NameValuePair("newPwdConfirm", 
"testNewPwd"));
@@ -90,10 +86,9 @@
        public void testChangeUserPasswordWrongOldPwd() throws IOException {
                testUserId = createTestUser();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId + ".changePassword.html";
 
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"changePassword"));
                postParams.add(new NameValuePair("oldPwd", "wrongTestPwd"));
                postParams.add(new NameValuePair("newPwd", "testNewPwd"));
                postParams.add(new NameValuePair("newPwdConfirm", 
"testNewPwd"));
@@ -106,10 +101,9 @@
        public void testChangeUserPasswordWrongConfirmPwd() throws IOException {
                testUserId = createTestUser();
                
-        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId;
+        String postUrl = HTTP_BASE_URL + "/system/userManager/user/" + 
testUserId + ".changePassword.html";
 
                List<NameValuePair> postParams = new ArrayList<NameValuePair>();
-               postParams.add(new NameValuePair(":operation", 
"changePassword"));
                postParams.add(new NameValuePair("oldPwd", "testPwd"));
                postParams.add(new NameValuePair("newPwd", "testNewPwd"));
                postParams.add(new NameValuePair("newPwdConfirm", 
"wrongTestNewPwd"));


Reply via email to