Skip to content

Commit fa655ee

Browse files
committed
Asserted behaviour is only for PURE_JAVA in Jaybird 5.0.x
1 parent d02caac commit fa655ee

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/test/org/firebirdsql/jdbc/FBResultSetTest.java

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,7 @@ class FBResultSetTest {
8181
" blob_bin BLOB SUB_TYPE BINARY" +
8282
")";
8383

84-
private static final String SELECT_TEST_TABLE =
85-
"SELECT id, str FROM test_table";
84+
private static final String SELECT_TEST_TABLE = "SELECT id, str FROM test_table order by id";
8685

8786
private static final String CREATE_TABLE_STATEMENT2 =
8887
"CREATE TABLE test_table2(" +
@@ -1561,7 +1560,7 @@ void insertRowImmediatelyAfterExecuteQuery_doesNotReportRowTwice(String scrollab
15611560
List<Object> insertRow = Arrays.asList(2, "2");
15621561
List<List<Object>> expectedRows =
15631562
"SERVER".equals(scrollableCursorPropertyValue)
1564-
&& getDefaultSupportInfo().supportsScrollableCursors()
1563+
&& canSupportServerSideScrollable()
15651564
? Arrays.asList(row1, insertRow)
15661565
: Arrays.asList(insertRow, row1);
15671566

@@ -1575,6 +1574,11 @@ && getDefaultSupportInfo().supportsScrollableCursors()
15751574
}
15761575
}
15771576

1577+
private static boolean canSupportServerSideScrollable() {
1578+
return "PURE_JAVA".equalsIgnoreCase(GDS_TYPE)
1579+
&& getDefaultSupportInfo().supportsScrollableCursors();
1580+
}
1581+
15781582
static Stream<String> scrollableCursorPropertyValues() {
15791583
// We are unconditionally emitting SERVER, to check if the value behaves appropriately on versions that do
15801584
// not support server-side scrollable cursors

0 commit comments

Comments
 (0)