From efa7ec172e3e6fcbd5ef0195680dfd33c8a590a0 Mon Sep 17 00:00:00 2001 From: Jan Schatteman Date: Wed, 29 Mar 2023 19:46:57 +0200 Subject: [PATCH] HHH-16406 - Fix error in PaginationTest for Sybase Signed-off-by: Jan Schatteman --- .../org/hibernate/orm/test/pagination/PaginationTest.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hibernate-core/src/test/java/org/hibernate/orm/test/pagination/PaginationTest.java b/hibernate-core/src/test/java/org/hibernate/orm/test/pagination/PaginationTest.java index ba238ef763..26a5b9655d 100644 --- a/hibernate-core/src/test/java/org/hibernate/orm/test/pagination/PaginationTest.java +++ b/hibernate-core/src/test/java/org/hibernate/orm/test/pagination/PaginationTest.java @@ -36,11 +36,11 @@ import static org.junit.jupiter.api.Assertions.assertTrue; "org/hibernate/orm/test/pagination/DataPoint.hbm.xml" } ) -@SessionFactory public class PaginationTest { public static final int NUMBER_OF_TEST_ROWS = 100; @Test + @SessionFactory public void testLimit(SessionFactoryScope scope) { scope.inTransaction( session -> { @@ -74,6 +74,7 @@ public class PaginationTest { } @Test + @SessionFactory public void testOffset(SessionFactoryScope scope) { scope.inTransaction( session -> { @@ -91,7 +92,7 @@ public class PaginationTest { assertEquals( firstDataPointHQL, - firstDataPointHQL, + firstDataPointCriteria, "The first entry should be the same in HQL and Criteria" ); assertEquals( 3, firstDataPointCriteria.getSequence(), "Wrong first result" ); @@ -103,7 +104,7 @@ public class PaginationTest { assertEquals( firstDataPointHQL, - firstDataPointHQL, + firstDataPointCriteria, "The first entry should be the same in HQL and Criteria" ); } @@ -111,6 +112,7 @@ public class PaginationTest { } @Test + @SessionFactory public void testLimitOffset(SessionFactoryScope scope) { scope.inTransaction( session -> {