File tree Expand file tree Collapse file tree
hibernate-core/src/test/java/org/hibernate/orm/test Expand file tree Collapse file tree Original file line number Diff line number Diff line change 55 branches :
66 # Pattern order matters: the last matching inclusion/exclusion wins
77 - ' 7.4'
8+ - ' spanner_fixes_7.4'
89 # We don't want to run CI on branches for dependabot, just on the PR.
910 - ' !dependabot/**'
1011 pull_request :
4546 - rdbms : mariadb
4647 - rdbms : postgresql
4748 - rdbms : spannerpgsql
49+ - rdbms : spanner
4850 - rdbms : edb
4951 - rdbms : oracle
5052 - rdbms : db2
Original file line number Diff line number Diff line change @@ -113,6 +113,8 @@ elif [ "$RDBMS" == "informix" ]; then
113113 goal=" -Pdb=informix"
114114elif [ " $RDBMS " == " spannerpgsql" ]; then
115115 goal=" -Pdb=spannerpgsql"
116+ elif [ " $RDBMS " == " spanner" ]; then
117+ goal=" -Pdb=spanner"
116118else
117119 echo " Invalid value for RDBMS: $RDBMS "
118120 exit 1
Original file line number Diff line number Diff line change @@ -14,6 +14,8 @@ elif [ "$RDBMS" == 'edb' ]; then
1414 bash $DIR /../docker_db.sh edb
1515elif [ " $RDBMS " == ' spannerpgsql' ]; then
1616 bash $DIR /../docker_db.sh spanner_pg
17+ elif [ " $RDBMS " == ' spanner' ]; then
18+ bash $DIR /../docker_db.sh spanner
1719elif [ " $RDBMS " == ' db2' ]; then
1820 bash $DIR /../docker_db.sh db2
1921elif [ " $RDBMS " == ' oracle' ]; then
Original file line number Diff line number Diff line change 2323import org .hibernate .dialect .HSQLDialect ;
2424import org .hibernate .dialect .MariaDBDialect ;
2525import org .hibernate .dialect .OracleDialect ;
26+ import org .hibernate .dialect .SpannerDialect ;
2627import org .hibernate .testing .orm .junit .DialectFeatureChecks ;
2728import org .hibernate .testing .orm .junit .DomainModel ;
2829import org .hibernate .testing .orm .junit .RequiresDialectFeature ;
@@ -144,7 +145,7 @@ void fetchJoinWithMaxResults(SessionFactoryScope scope) {
144145 assertTrue ( generated .contains ( "author_book_link" ) );
145146 assertTrue ( generated .contains ( "book_entity" ) );
146147 var dialect = scope .getSessionFactory ().getJdbcServices ().getDialect ();
147- if ( !(dialect instanceof HSQLDialect ) && !(dialect instanceof MariaDBDialect ) && !(dialect instanceof OracleDialect ) ) {
148+ if ( !(dialect instanceof HSQLDialect ) && !(dialect instanceof MariaDBDialect ) && !(dialect instanceof OracleDialect ) && !( dialect instanceof SpannerDialect ) ) {
148149 final int existsStart = generated .indexOf ( "exists(select 1 from author_book_link" );
149150 final int existsWhere = generated .indexOf ( " where" , existsStart );
150151 assertTrue ( existsStart >= 0 );
Original file line number Diff line number Diff line change 2121import org .hibernate .dialect .HSQLDialect ;
2222import org .hibernate .dialect .MariaDBDialect ;
2323import org .hibernate .dialect .OracleDialect ;
24+ import org .hibernate .dialect .SpannerDialect ;
2425import org .hibernate .testing .orm .junit .DialectFeatureChecks ;
2526import org .hibernate .testing .orm .junit .DomainModel ;
2627import org .hibernate .testing .orm .junit .RequiresDialectFeature ;
@@ -118,7 +119,7 @@ void fetchJoinWithMaxResults(SessionFactoryScope scope) {
118119 assertTrue ( generated .contains ( "from (select" ) );
119120 assertTrue ( generated .contains ( "item_entity" ) );
120121 var dialect = scope .getSessionFactory ().getJdbcServices ().getDialect ();
121- if ( !(dialect instanceof HSQLDialect ) && !(dialect instanceof MariaDBDialect ) && !(dialect instanceof OracleDialect ) ) {
122+ if ( !(dialect instanceof HSQLDialect ) && !(dialect instanceof MariaDBDialect ) && !(dialect instanceof OracleDialect ) && !( dialect instanceof SpannerDialect ) ) {
122123 final int existsStart = generated .indexOf ( "exists(select 1 from item_entity" );
123124 final int existsWhere = generated .indexOf ( " where" , existsStart );
124125 assertTrue ( existsStart >= 0 );
Original file line number Diff line number Diff line change @@ -642,6 +642,7 @@ public void testDateTruncWithOffsetFunction(SessionFactoryScope scope) {
642642 }
643643
644644 @ Test
645+ @ SkipForDialect (dialectClass = SpannerDialect .class , reason = "date and timestamp are not compatible" )
645646 public void testDateTruncWithLocalDatetimeMinusLocalDate (SessionFactoryScope scope ) {
646647 scope .inTransaction ( session ->
647648 assertThat ( session .createQuery ( "select trunc(local datetime, day) - local date" , Duration .class )
You can’t perform that action at this time.
0 commit comments