Closed GoogleCodeExporter closed 9 years ago
Failed tests:
test_in_classpath(org.nutz.resource.ScansTest)
test_in_jar(org.nutz.resource.ScansTest)
test_classes_in_jar(org.nutz.resource.ScansTest)
test_classes_in_package_path(org.nutz.resource.ScansTest)
test_in_classpath(org.nutz.resource.ScansTest)
test_in_jar(org.nutz.resource.ScansTest)
test_classes_in_jar(org.nutz.resource.ScansTest)
test_classes_in_package_path(org.nutz.resource.ScansTest)
这些是Scans的问题.
Original comment by wendal1985@gmail.com
on 20 Jan 2011 at 10:57
单独运行AllNormal测试,pass
按AllMapping --> AllNormal顺序执行, fail
按AllNormal --> AllMapping 顺序执行, pass
只执行 AllMapping中的DynamicManyManyTest ,然后继续执行AllNormal
fail
将语句: pojos.init(); 加入SimpleDaoTest的before方法的第一行,
可以将fail的个数减至1
Original comment by wendal1985@gmail.com
on 20 Jan 2011 at 11:31
不知到 BoneCP + Mysql 有没有这个问题
Original comment by zozoh...@gmail.com
on 20 Jan 2011 at 3:25
应该没有,我在使用呢。今天找个时间试试。
就是,如果将Nutzs类的获取Ioc的方法改为:
public static Ioc getIoc(String key) {
return new NutIoc(new JsonLoader(key));
}
即每个获取Ioc实例都是新建的,就会是之前的fail的测试全部p
ass
故,应该是多个测试共有同一个数据源导致的。
Original comment by wendal1985@gmail.com
on 21 Jan 2011 at 12:18
换成这种方式的时候,其他的又有问题了。
Original comment by sjbwy...@gmail.com
on 21 Jan 2011 at 2:17
Attachments:
添加了测试用例 BoneCP_Test 能够重现这个问题
Original comment by wendal1985@gmail.com
on 26 Jan 2011 at 1:02
的确,单独运行也是出
org.nutz.dao.DaoException: !Nutz SQL Error: 'SELECT COUNT(*) FROM t_pet '
PreparedStatement:
'SELECT COUNT(*) FROM t_pet '
at org.nutz.dao.sql.SqlImpl.execute(SqlImpl.java:127)
at org.nutz.dao.impl.DefaultDaoExecutor$1.invoke(DefaultDaoExecutor.java:33)
at org.nutz.dao.ConnectionHolder.invoke(ConnectionHolder.java:43)
at org.nutz.dao.impl.DefaultDaoRunner.run(DefaultDaoRunner.java:21)
at org.nutz.dao.impl.DefaultDaoExecutor.execute(DefaultDaoExecutor.java:20)
at org.nutz.dao.impl.NutDao.execute(NutDao.java:233)
at org.nutz.dao.impl.NutDao.count(NutDao.java:254)
at org.nutz.dao.impl.NutDao.count(NutDao.java:246)
at org.nutz.dao.test.normal.BoneCP_Test.clear_links(BoneCP_Test.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:76)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: org.h2.jdbc.JdbcSQLException: Timeout trying to lock table "T_PET";
SQL statement:
SELECT COUNT(*) FROM t_pet [50200-125]
at org.h2.message.Message.getSQLException(Message.java:111)
at org.h2.message.Message.getSQLException(Message.java:122)
at org.h2.message.Message.getSQLException(Message.java:75)
at org.h2.table.TableData.doLock(TableData.java:495)
at org.h2.table.TableData.lock(TableData.java:433)
at org.h2.table.TableFilter.lock(TableFilter.java:119)
at org.h2.command.dml.Select.queryWithoutCache(Select.java:546)
at org.h2.command.dml.Query.query(Query.java:243)
at org.h2.command.CommandContainer.query(CommandContainer.java:81)
at org.h2.command.Command.executeQuery(Command.java:133)
at org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:98)
at com.jolbox.bonecp.PreparedStatementHandle.executeQuery(PreparedStatementHandle.java:197)
at org.nutz.dao.sql.SqlImpl.execute(SqlImpl.java:75)
... 32 more
Original comment by zozoh...@gmail.com
on 26 Jan 2011 at 1:56
提交了 r1788
在 pojo.js
里增加了一段注释的配置,当把注释取消后,就能重现这个
bug
Original comment by zozoh...@gmail.com
on 26 Jan 2011 at 1:59
https://bugs.launchpad.net/bugs/721739
0.7.1rc4没有这个问题.
Original comment by wendal1985@gmail.com
on 21 Feb 2011 at 12:17
加了一个标注,1.b.36 发布前再测测,没问题就可以 fix
了,哈
Original comment by zozoh...@gmail.com
on 21 Feb 2011 at 12:37
Original comment by zozoh...@gmail.com
on 24 Mar 2011 at 4:19
Original comment by zozoh...@gmail.com
on 24 Mar 2011 at 4:21
Original issue reported on code.google.com by
sjbwy...@gmail.com
on 20 Jan 2011 at 10:56Attachments: