提交 b8f7ce5c authored 作者: noelgrandin@gmail.com's avatar noelgrandin@gmail.com

fix unit test

上级 347791c1
...@@ -406,15 +406,14 @@ public class TestTriggersConstraints extends TestBase implements Trigger { ...@@ -406,15 +406,14 @@ public class TestTriggersConstraints extends TestBase implements Trigger {
assertSingleValue(stat, callSeq, 1); assertSingleValue(stat, callSeq, 1);
conn.setAutoCommit(false); conn.setAutoCommit(false);
if (asSource) { if (asSource) {
String triggerClassName = this.getClass().getName() + "." + String triggerClassName = this.getClass().getName() + "."
TestTriggerAlterTable.class.getSimpleName(); + TestTriggerAlterTable.class.getSimpleName();
stat.execute( stat.execute("create trigger test_upd before insert on test "
"create trigger test_upd before insert on test " + + "as $$org.h2.api.Trigger create() " + "{ return new "
"as $$org.h2.api.Trigger create() " + + triggerClassName + "(); } $$");
"{ return new " + triggerClassName + "(\"seq\"); } $$");
} else { } else {
stat.execute("create trigger test_upd before insert on test call \"" + stat.execute("create trigger test_upd before insert on test call \""
TestTriggerAlterTable.class.getName() + "\""); + TestTriggerAlterTable.class.getName() + "\"");
} }
stat.execute("insert into test values(1)"); stat.execute("insert into test values(1)");
assertSingleValue(stat, callSeq, 3); assertSingleValue(stat, callSeq, 3);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论