提交 847ab2c2 authored 作者: Evgenij Ryazanov's avatar Evgenij Ryazanov

Fix ResultWithPaddedStrings and TestValue

上级 46dc74c4
......@@ -65,7 +65,7 @@ public class ResultWithPaddedStrings implements ResultInterface {
precision = 1;
}
String s = row[i].getString();
if (s.length() < precision) {
if (s != null && s.length() < precision) {
/*
* Use ValueString to avoid truncation of spaces. There is
* no difference between ValueStringFixed and ValueString
......
......@@ -414,7 +414,11 @@ public class TestValue extends TestDb {
ValueJavaObject voString = ValueJavaObject.getNoCopy(
new String("This is not a ValueUuid object"), null, null);
assertThrows(DbException.class, voString).convertTo(Value.UUID);
try {
voString.convertTo(Value.UUID);
fail();
} catch (DbException expected) {
}
}
private void testModulusDouble() {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论