[INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Building AppFuse Modular Application - Core [INFO] task-segment: [install] [INFO] ------------------------------------------------------------------------ [INFO] [resources:resources {execution: default-resources}] [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 8 resources [INFO] [compiler:compile {execution: default-compile}] [INFO] Nothing to compile - all classes are up to date [INFO] [resources:testResources {execution: default-testResources}] [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 12 resources [INFO] Preparing hibernate3:hbm2ddl [WARNING] Removing: hbm2ddl from forked lifecycle, to prevent recursive invocation. [INFO] [resources:resources {execution: default-resources}] [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 8 resources [INFO] [hibernate3:hbm2ddl {execution: default}] [INFO] Configuration XML file loaded: file:/C:/Documents%20and%20Settings/Administrator/cms2/core/src/main/resources/hibernate.cfg.xml [INFO] Configuration XML file loaded: file:/C:/Documents%20and%20Settings/Administrator/cms2/core/src/main/resources/hibernate.cfg.xml [INFO] Configuration Properties file loaded: C:\Documents and Settings\Administrator\cms2\core\target\test-classes\jdbc.properties alter table user_role drop foreign key FK143BF46ABFCC459A; alter table user_role drop foreign key FK143BF46A64F7097A; drop table if exists app_user; drop table if exists role; drop table if exists user_role; create table app_user (id bigint not null auto_increment, account_expired bit not null, account_locked bit not null, address varchar(150), city varchar(50), country varchar(100), postal_code varchar(15), province varchar(100), credentials_expired bit not null, email varchar(255) not null unique, account_enabled bit, first_name varchar(50) not null, last_name varchar(50) not null, password varchar(255) not null, password_hint varchar(255), phone_number varchar(255), username varchar(50) not null unique, version integer, website varchar(255), primary key (id)) ENGINE=InnoDB; create table role (id bigint not null auto_increment, description varchar(64), name varchar(20), primary key (id)) ENGINE=InnoDB; create table user_role (user_id bigint not null, role_id bigint not null, primary key (user_id, role_id)) ENGINE=InnoDB; alter table user_role add index FK143BF46ABFCC459A (role_id), add constraint FK143BF46ABFCC459A foreign key (role_id) references role (id); alter table user_role add index FK143BF46A64F7097A (user_id), add constraint FK143BF46A64F7097A foreign key (user_id) references app_user (id); [WARNING] 2 errors occurred while performing <hbm2ddl>. [ERROR] Error #1: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'cms2.user_role' doesn't exist [ERROR] Error #1: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'cms2.user_role' doesn't exist [INFO] [compiler:testCompile {execution: default-testCompile}] [INFO] Nothing to compile - all classes are up to date [INFO] [dbunit:operation {execution: test-compile}] [INFO] [surefire:test {execution: default-test}] [INFO] Surefire report directory: C:\Documents and Settings\Administrator\cms2\core\target\surefire-reports ------------------------------------------------------- T E S T S ------------------------------------------------------- Running com.zonkey.dao.RoleDaoTest Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 9.437 sec Running com.zonkey.util.DateUtilTest DEBUG - DateUtilTest.testGetDate(44) | db date to convert: Wed Jun 08 13:16:26 CST 2011 DEBUG - DateUtilTest.testGetDate(50) | converted ui date: 06/08/2011 DEBUG - DateUtilTest.testGetDateTime(58) | entered 'testGetDateTime' method DEBUG - DateUtilTest.testGetDateTime(62) | 13:16 WARN - DateUtil.getDateTime(149) | aDate is null! DEBUG - DateUtil.convertStringToDate(92) | converting '06/08/2011' to date with mask 'MM/dd/yyyy' Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.063 sec Running com.zonkey.dao.LookupDaoTest DEBUG - LookupDaoHibernate.getRoles(38) | Retrieving all role names... DEBUG - LookupDaoTest.testGetRoles(21) | [ROLE_ADMIN, ROLE_USER] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.14 sec Running com.zonkey.service.impl.LookupManagerImplTest DEBUG - LookupManagerImplTest.testGetAllRoles(29) | entered 'testGetAllRoles' method Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.125 sec Running com.zonkey.util.DateConverterTest Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.031 sec Running com.zonkey.service.impl.UserManagerImplTest WARN - UserManagerImpl.saveUser(89) | PasswordEncoder not set, skipping password encryption... DEBUG - UserManagerImpl.removeUser(109) | removing user: 5 WARN - UserManagerImpl.saveUser(89) | PasswordEncoder not set, skipping password encryption... WARN - UserManagerImpl.saveUser(89) | PasswordEncoder not set, skipping password encryption... WARN - UserManagerImpl.saveUser(96) | DEBUG - UserManagerImplTest.testUserExistsException(134) | expected exception: User 'admin' already exists! Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.219 sec Running com.zonkey.service.UserManagerTest DEBUG - UserManagerTest.testGetUser(25) | com.zonkey.model.User@14ff81a[username=user,enabled=true,accountExpired=false,credentialsExpired=false,accountLocked=false,Granted Authorities: ,ROLE_USER] DEBUG - UserDaoHibernate.saveUser(49) | user's id: null DEBUG - UserManagerTest.testAddAndRemoveUser(55) | removing user... DEBUG - UserManagerImpl.removeUser(109) | removing user: 1 DEBUG - UserManagerTest.testAddAndRemoveUser(63) | org.springframework.security.core.userdetails.UsernameNotFoundException: user 'john' not found... DEBUG - UserManagerTest.testSaveUser(34) | saving user with updated phone number: com.zonkey.model.User@1966070[username=user,enabled=true,accountExpired=false,credentialsExpired=false,accountLocked=false,Granted Authorities: ,ROLE_USER] DEBUG - UserDaoHibernate.saveUser(49) | user's id: -1 Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.531 sec Running com.zonkey.dao.hibernate.HibernateConfigurationTest DEBUG - HibernateConfigurationTest.testColumnMapping(25) | Trying select * from: com.zonkey.model.User DEBUG - HibernateConfigurationTest.testColumnMapping(28) | ok: com.zonkey.model.User DEBUG - HibernateConfigurationTest.testColumnMapping(25) | Trying select * from: com.zonkey.model.Role DEBUG - HibernateConfigurationTest.testColumnMapping(28) | ok: com.zonkey.model.Role Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.063 sec Running com.zonkey.dao.UserDaoTest WARN - GenericDaoHibernate.get(106) | Uh oh, 'class com.zonkey.model.User' object with id '1000' not found... DEBUG - UserDaoTest.testGetUserPassword(53) | password: 12dea96fec20593566ab75692c9949596833adc9 DEBUG - UserDaoHibernate.saveUser(49) | user's id: -1 DEBUG - UserDaoHibernate.saveUser(49) | user's id: null WARN - JDBCExceptionReporter.logExceptions(233) | SQL Error: 1062, SQLState: 23000 ERROR - JDBCExceptionReporter.logExceptions(234) | Duplicate entry '[email protected]' for key 'email' DEBUG - UserDaoHibernate.saveUser(49) | user's id: -1 DEBUG - UserDaoHibernate.saveUser(49) | user's id: -1 DEBUG - UserDaoHibernate.saveUser(49) | user's id: -1 DEBUG - UserDaoHibernate.saveUser(49) | user's id: null WARN - GenericDaoHibernate.get(106) | Uh oh, 'class com.zonkey.model.User' object with id '3' not found... Tests run: 9, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.672 sec <<< FAILURE! Running com.zonkey.service.MailEngineTest Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.937 sec Running com.zonkey.dao.GenericDaoTest Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.047 sec Running com.zonkey.service.UserExistsExceptionTest DEBUG - UserExistsExceptionTest.testAddExistingUser(27) | entered 'testAddExistingUser' method DEBUG - UserDaoHibernate.saveUser(49) | user's id: null WARN - JDBCExceptionReporter.logExceptions(233) | SQL Error: 1062, SQLState: 23000 ERROR - JDBCExceptionReporter.logExceptions(234) | Duplicate entry '[email protected]' for key 'email' WARN - UserManagerImpl.saveUser(96) | could not insert: [com.zonkey.model.User]; SQL [insert into app_user (account_expired, account_locked, address, city, country, postal_code, province, credentials_expired, email, account_enabled, first_name, last_name, password, password_hint, phone_number, username, version, website) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)]; constraint [null]; nested exception is org.hibernate.exception.ConstraintViolationException: could not insert: [com.zonkey.model.User] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.844 sec Running com.zonkey.service.impl.UserSecurityAdviceTest WARN - UserSecurityAdvice.before(72) | Access Denied: 'user' tried to modify 'admin'! WARN - UserSecurityAdvice.before(93) | Access Denied: 'user' tried to change their role(s)! WARN - UserSecurityAdvice.before(93) | Access Denied: 'user' tried to change their role(s)! Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.531 sec Results : Tests in error: testUserSearch(com.zonkey.dao.UserDaoTest) Tests run: 49, Failures: 0, Errors: 1, Skipped: 0 [INFO] ------------------------------------------------------------------------ [ERROR] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] There are test failures. Please refer to C:\Documents and Settings\Administrator\cms2\core\target\surefire-reports for the individual test results. [INFO] ------------------------------------------------------------------------ [INFO] For more information, run Maven with the -e switch [INFO] ------------------------------------------------------------------------ [INFO] Total time: 29 seconds [INFO] Finished at: Wed Jun 08 13:16:32 CST 2011 [INFO] Final Memory: 25M/46M [INFO] ------------------------------------------------------------------------