Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
H
h2database
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
Administrator
h2database
Commits
bc21e0a6
提交
bc21e0a6
authored
7 年前
作者:
Owner
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Issues#458 Reverted test script simple changes
上级
35b4fc56
master
noel-pr1
stumc-Issue#576
version-1.4.198
version-1.4.197
无相关合并请求
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
8 行增加
和
15 行删除
+8
-15
TestScriptSimple.java
h2/src/test/org/h2/test/db/TestScriptSimple.java
+2
-12
ImmutableArray.java
h2/src/tools/org/h2/dev/util/ImmutableArray.java
+2
-1
ImmutableArray2.java
h2/src/tools/org/h2/dev/util/ImmutableArray2.java
+2
-1
ImmutableArray3.java
h2/src/tools/org/h2/dev/util/ImmutableArray3.java
+2
-1
没有找到文件。
h2/src/test/org/h2/test/db/TestScriptSimple.java
浏览文件 @
bc21e0a6
...
...
@@ -11,8 +11,6 @@ import java.io.LineNumberReader;
import
java.sql.Connection
;
import
java.sql.ResultSet
;
import
java.sql.SQLException
;
import
java.util.ArrayList
;
import
java.util.List
;
import
org.h2.test.TestBase
;
import
org.h2.util.ScriptReader
;
...
...
@@ -45,7 +43,6 @@ public class TestScriptSimple extends TestBase {
InputStream
is
=
getClass
().
getClassLoader
().
getResourceAsStream
(
inFile
);
LineNumberReader
lineReader
=
new
LineNumberReader
(
new
InputStreamReader
(
is
,
"Cp1252"
));
List
<
Throwable
>
exceptions
=
new
ArrayList
<>();
try
(
ScriptReader
reader
=
new
ScriptReader
(
lineReader
))
{
while
(
true
)
{
String
sql
=
reader
.
readStatement
();
...
...
@@ -68,22 +65,15 @@ public class TestScriptSimple extends TestBase {
}
else
{
conn
.
createStatement
().
execute
(
sql
);
}
}
catch
(
Throwable
e
)
{
}
catch
(
SQLException
e
)
{
System
.
out
.
println
(
sql
);
System
.
out
.
println
(
" at line#"
+
lineReader
.
getLineNumber
()+
" of file "
+
inFile
);
e
.
printStackTrace
();
exceptions
.
add
(
e
);
throw
e
;
}
}
}
conn
.
close
();
deleteDb
(
"scriptSimple"
);
if
(
exceptions
.
size
()!=
0
){
String
message
=
"Failed test, detected assertions="
+
exceptions
.
size
();
System
.
out
.
println
(
message
);
throw
new
AssertionError
(
message
);
}
}
private
void
reconnect
()
throws
SQLException
{
...
...
This diff is collapsed.
Click to expand it.
h2/src/tools/org/h2/dev/util/ImmutableArray.java
浏览文件 @
bc21e0a6
...
...
@@ -111,6 +111,7 @@ public final class ImmutableArray<K> implements Iterable<K> {
* @param array the data
* @return the new immutable array
*/
@SafeVarargs
public
static
<
K
>
ImmutableArray
<
K
>
create
(
K
...
array
)
{
return
new
ImmutableArray
<
K
>(
array
);
}
...
...
This diff is collapsed.
Click to expand it.
h2/src/tools/org/h2/dev/util/ImmutableArray2.java
浏览文件 @
bc21e0a6
...
...
@@ -151,6 +151,7 @@ public final class ImmutableArray2<K> implements Iterable<K> {
* @param array the data
* @return the new immutable array
*/
@SafeVarargs
public
static
<
K
>
ImmutableArray2
<
K
>
create
(
K
...
array
)
{
return
new
ImmutableArray2
<
K
>(
array
,
array
.
length
);
}
...
...
This diff is collapsed.
Click to expand it.
h2/src/tools/org/h2/dev/util/ImmutableArray3.java
浏览文件 @
bc21e0a6
...
...
@@ -84,6 +84,7 @@ public abstract class ImmutableArray3<K> implements Iterable<K> {
* @param array the data
* @return the new immutable array
*/
@SafeVarargs
public
static
<
K
>
ImmutableArray3
<
K
>
create
(
K
...
array
)
{
return
new
Plain
<
K
>(
array
);
}
...
...
This diff is collapsed.
Click to expand it.
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论