← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 16812: Minor

 

------------------------------------------------------------
revno: 16812
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2014-09-25 09:47:41 +0200
message:
  Minor
modified:
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/security/SecurityServiceTest.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/security/SecurityServiceTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/security/SecurityServiceTest.java	2014-09-24 06:56:36 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/security/SecurityServiceTest.java	2014-09-25 07:47:41 +0000
@@ -116,15 +116,15 @@
         //
         // canRestoreNow()
         //
-        assertFalse( securityService.canRestoreNow( otherCredentials, token, code, RestoreType.RECOVER_PASSWORD ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, "wrongToken", code, RestoreType.RECOVER_PASSWORD ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, token, "wrongCode", RestoreType.RECOVER_PASSWORD ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, token, code, RestoreType.INVITE ) );
-
-        assertTrue( securityService.canRestoreNow( credentials, token, code, RestoreType.RECOVER_PASSWORD ) );
+        assertFalse( securityService.canRestore( otherCredentials, token, code, RestoreType.RECOVER_PASSWORD ) );
+
+        assertFalse( securityService.canRestore( credentials, "wrongToken", code, RestoreType.RECOVER_PASSWORD ) );
+
+        assertFalse( securityService.canRestore( credentials, token, "wrongCode", RestoreType.RECOVER_PASSWORD ) );
+
+        assertFalse( securityService.canRestore( credentials, token, code, RestoreType.INVITE ) );
+
+        assertTrue( securityService.canRestore( credentials, token, code, RestoreType.RECOVER_PASSWORD ) );
 
         //
         // restore()
@@ -185,15 +185,15 @@
         //
         // canRestoreNow()
         //
-        assertFalse( securityService.canRestoreNow( otherCredentials, token, code, RestoreType.INVITE ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, "wrongToken", code, RestoreType.INVITE ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, token, "wrongCode", RestoreType.INVITE ) );
-
-        assertFalse( securityService.canRestoreNow( credentials, token, code, RestoreType.RECOVER_PASSWORD ) );
-
-        assertTrue( securityService.canRestoreNow( credentials, token, code, RestoreType.INVITE ) );
+        assertFalse( securityService.canRestore( otherCredentials, token, code, RestoreType.INVITE ) );
+
+        assertFalse( securityService.canRestore( credentials, "wrongToken", code, RestoreType.INVITE ) );
+
+        assertFalse( securityService.canRestore( credentials, token, "wrongCode", RestoreType.INVITE ) );
+
+        assertFalse( securityService.canRestore( credentials, token, code, RestoreType.RECOVER_PASSWORD ) );
+
+        assertTrue( securityService.canRestore( credentials, token, code, RestoreType.INVITE ) );
 
         //
         // restore()