1 63 package com.ivata.groupware.admin.security; 64 import net.sf.hibernate.HibernateException; 65 66 import com.ivata.groupware.admin.AdminTestCase; 67 import com.ivata.groupware.admin.security.server.PlainTextSecurityServer; 68 import com.ivata.groupware.admin.security.server.SecurityServer; 69 import com.ivata.groupware.admin.security.server.SecuritySession; 70 import com.ivata.groupware.business.addressbook.person.PersonDO; 71 import com.ivata.groupware.container.persistence.QueryPersistenceManager; 72 import com.ivata.mask.DefaultMaskFactory; 73 import com.ivata.mask.field.DefaultFieldValueConvertorFactory; 74 import com.ivata.mask.persistence.PersistenceSession; 75 import com.ivata.mask.util.SystemException; 76 77 83 public class SecurityImplTest extends AdminTestCase { 84 85 QueryPersistenceManager persistenceManager; 86 PersistenceSession persistenceSession; 87 88 PersonDO person = null; 89 90 95 private SecurityImpl security; 96 97 101 public SecurityImplTest(String arg0) throws HibernateException { 102 super(arg0); 103 } 104 SecuritySession securitySession; 105 106 109 protected synchronized void setUp() throws Exception { 110 super.setUp(); 111 securitySession = getSecuritySession(); 112 persistenceManager = getHibernateManager(); 113 persistenceSession = getHibernateSession(); 114 SecurityServer server = new PlainTextSecurityServer(persistenceManager); 115 security = new SecurityImpl(persistenceManager, server, 116 new DefaultMaskFactory(), Boolean.FALSE); 117 } 118 119 122 protected void tearDown() throws Exception { 123 super.tearDown(); 124 if (person != null) { 125 persistenceManager.remove(persistenceSession, person); 126 } 127 } 128 129 private PersonDO createTestPerson() throws SystemException { 130 person = new PersonDO(); 131 person.setCompany("test company"); 132 person.setFileAs("file as"); 133 person.setFirstNames("first names"); 134 person.setLastName("security test"); 135 persistenceManager.add(persistenceSession, person); 136 return person; 137 } 138 139 140 public void testAddUserToPerson() throws SystemException { 141 160 } 161 162 public void testAmendUserName() throws SystemException { 163 } 164 165 public void testCheckPassword() { 166 } 167 168 public void testCreatePrivateGroups() { 169 } 170 171 public void testEnableUser() { 172 } 173 174 public void testFindUserByName() { 175 } 176 177 public void testGetSystemUserName() { 178 } 179 180 public void testGetUserNameFromSystemUserName() { 181 } 182 183 public void testIsUserEnabled() { 184 } 185 186 public void testLogin() { 187 } 188 189 public void testLoginAgain() { 190 } 191 192 public void testLoginGuest() { 193 } 194 195 public void testRemoveUser() { 196 } 197 198 public void testRestoreUser() { 199 } 200 201 public void testSetPassword() { 202 } 203 204 } 205 | Popular Tags |