有没有熟悉Appfuse的?Help me!
在运行Appfuse1.9时,按照其README上的操作,前面四步没问题,启动tomcat也没有问题,但是运行ant test-canoo -Dtestcase=Login时出现错误:
Login:
BUILD FAILED
D:\appfuse\build.xml:599: The following error occurred while executing this line
:
D:\appfuse\test\web\web-tests.xml:28: Canoo Webtest: R_1393.
Test failed.
Test step verifytitle (D:\appfuse\test\web\login.xml:2: ) named "we should see
the login title" failed with message "Wrong document title found! Expected ".*??
??????????.*" but got "登录 ¦ AppFuse""
Total time: 19 seconds
然后运行ant test-reports后查看html文档,错误如下:
Name Tests Errors Failures Time(s) Time Stamp Host
GenericDaoTest 1 0 0 5.094 2007-03-14T03:14:51 xiao
LookupDaoTest 1 0 0 0.422 2007-03-14T03:14:55 xiao
RoleDaoTest 4 4 0 0.422 2007-03-14T03:14:56 xiao
UserDaoTest 5 2 0 0.329 2007-03-14T03:14:56 xiao
然后在页面的时候登陆和注册总是提示错误,奇怪的是在UserDaoTest中testGetUserInvalid,testGetUser,testUpdateUser测试正确,testAddUserRole,testAddAndRemoveUser却错误,提示为
testAddUserRole Error JDBC exception on Hibernate data access; nested exception is org.hibernate.exception.GenericJDBCException: could not execute query
org.springframework.orm.hibernate3.HibernateJdbcException: JDBC exception on Hibernate data access; nested exception is org.hibernate.exception.GenericJDBCException: could not execute query
Caused by: org.hibernate.exception.GenericJDBCException: could not execute query
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2147)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028)
at org.hibernate.loader.Loader.list(Loader.java:2023)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:393)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
at org.springframework.orm.hibernate3.HibernateTemplate$29.doInHibernate(HibernateTemplate.java:839)
at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:362)
at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:830)
at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:826)
at org.appfuse.dao.hibernate.RoleDaoHibernate.getRoleByName(RoleDaoHibernate.java:30)
at org.appfuse.dao.UserDaoTest.testAddUserRole(UserDaoTest.java:68)
at org.springframework.test.ConditionalTestCase.runBare(ConditionalTestCase.java:69)
Caused by: java.sql.SQLException: Illegal mix of collations (gbk_chinese_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation '='
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2870)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1573)
at com.mysql.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:1160)
at com.mysql.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:685)
at com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:1262)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1668)
at org.hibernate.loader.Loader.doQuery(Loader.java:662)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2144)
用的是appfuse-springmvc-1.9.4,tomcat5.5,SMTP是IIS
有谁知道解决方法的还请告知!谢谢啦!
Login:
BUILD FAILED
D:\appfuse\build.xml:599: The following error occurred while executing this line
:
D:\appfuse\test\web\web-tests.xml:28: Canoo Webtest: R_1393.
Test failed.
Test step verifytitle (D:\appfuse\test\web\login.xml:2: ) named "we should see
the login title" failed with message "Wrong document title found! Expected ".*??
??????????.*" but got "登录 ¦ AppFuse""
Total time: 19 seconds
然后运行ant test-reports后查看html文档,错误如下:
Name Tests Errors Failures Time(s) Time Stamp Host
GenericDaoTest 1 0 0 5.094 2007-03-14T03:14:51 xiao
LookupDaoTest 1 0 0 0.422 2007-03-14T03:14:55 xiao
RoleDaoTest 4 4 0 0.422 2007-03-14T03:14:56 xiao
UserDaoTest 5 2 0 0.329 2007-03-14T03:14:56 xiao
然后在页面的时候登陆和注册总是提示错误,奇怪的是在UserDaoTest中testGetUserInvalid,testGetUser,testUpdateUser测试正确,testAddUserRole,testAddAndRemoveUser却错误,提示为
testAddUserRole Error JDBC exception on Hibernate data access; nested exception is org.hibernate.exception.GenericJDBCException: could not execute query
org.springframework.orm.hibernate3.HibernateJdbcException: JDBC exception on Hibernate data access; nested exception is org.hibernate.exception.GenericJDBCException: could not execute query
Caused by: org.hibernate.exception.GenericJDBCException: could not execute query
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2147)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028)
at org.hibernate.loader.Loader.list(Loader.java:2023)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:393)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
at org.springframework.orm.hibernate3.HibernateTemplate$29.doInHibernate(HibernateTemplate.java:839)
at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:362)
at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:830)
at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:826)
at org.appfuse.dao.hibernate.RoleDaoHibernate.getRoleByName(RoleDaoHibernate.java:30)
at org.appfuse.dao.UserDaoTest.testAddUserRole(UserDaoTest.java:68)
at org.springframework.test.ConditionalTestCase.runBare(ConditionalTestCase.java:69)
Caused by: java.sql.SQLException: Illegal mix of collations (gbk_chinese_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation '='
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2870)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1573)
at com.mysql.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:1160)
at com.mysql.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:685)
at com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:1262)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1668)
at org.hibernate.loader.Loader.doQuery(Loader.java:662)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2144)
用的是appfuse-springmvc-1.9.4,tomcat5.5,SMTP是IIS
有谁知道解决方法的还请告知!谢谢啦!