Skip to content

Commit 08b556d

Browse files
author
mpv1989
committed
Fix test
1 parent bca0cb8 commit 08b556d

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

src/test/java/com/arangodb/ArangoDatabaseTest.java

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1070,15 +1070,17 @@ public void getDocument() {
10701070
}
10711071

10721072
@Test
1073-
@Ignore
10741073
public void shouldIncludeExceptionMessage() {
1075-
final String exceptionMessage = "My error context";
1076-
final String action = "function (params) {" + "throw '" + exceptionMessage + "';" + "}";
1077-
try {
1078-
db.transaction(action, VPackSlice.class, null);
1079-
fail();
1080-
} catch (final ArangoDBException e) {
1081-
assertTrue(e.getException().contains(exceptionMessage));
1074+
final String version = db.getVersion().getVersion();
1075+
if (version.startsWith("3.1") || version.startsWith("3.0")) {
1076+
final String exceptionMessage = "My error context";
1077+
final String action = "function (params) {" + "throw '" + exceptionMessage + "';" + "}";
1078+
try {
1079+
db.transaction(action, VPackSlice.class, null);
1080+
fail();
1081+
} catch (final ArangoDBException e) {
1082+
assertTrue(e.getException().contains(exceptionMessage));
1083+
}
10821084
}
10831085
}
10841086

0 commit comments

Comments
 (0)