HHH-6841 Applied @SkipForDialects to a couple of tests

This commit is contained in:
Brett Meyer 2013-02-14 18:12:08 -05:00
parent 6b4b6cc27f
commit 3797e2150a
2 changed files with 16 additions and 11 deletions

View File

@ -26,7 +26,8 @@
*/ */
package org.hibernate.test.annotations.manytoonewithformula; package org.hibernate.test.annotations.manytoonewithformula;
import org.junit.Test; import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import org.hibernate.Session; import org.hibernate.Session;
import org.hibernate.Transaction; import org.hibernate.Transaction;
@ -36,10 +37,9 @@ import org.hibernate.dialect.Oracle8iDialect;
import org.hibernate.dialect.SQLServer2005Dialect; import org.hibernate.dialect.SQLServer2005Dialect;
import org.hibernate.testing.RequiresDialect; import org.hibernate.testing.RequiresDialect;
import org.hibernate.testing.SkipForDialect; import org.hibernate.testing.SkipForDialect;
import org.hibernate.testing.SkipForDialects;
import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase; import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
/** /**
* @author Sharath Reddy * @author Sharath Reddy
@ -155,8 +155,11 @@ public class ManyToOneWithFormulaTest extends BaseCoreFunctionalTestCase {
} }
@Test @Test
@SkipForDialect(value = { HSQLDialect.class, SQLServer2005Dialect.class, Oracle8iDialect.class, DB2Dialect.class }, @SkipForDialects( {
comment = "The used join conditions does not work in HSQLDB. See HHH-4497. And oracle/db2 do not support 'substring' function") @SkipForDialect( value = { HSQLDialect.class }, comment = "The used join conditions does not work in HSQLDB. See HHH-4497." ),
@SkipForDialect( value = { SQLServer2005Dialect.class } ),
@SkipForDialect( value = { Oracle8iDialect.class }, comment = "Oracle/DB2 do not support 'substring' function" ),
@SkipForDialect( value = { DB2Dialect.class }, comment = "Oracle/DB2 do not support 'substring' function" ) } )
public void testManyToOneFromNonPkToNonPk() throws Exception { public void testManyToOneFromNonPkToNonPk() throws Exception {
// also tests usage of the stand-alone @JoinFormula annotation (i.e. not wrapped within @JoinColumnsOrFormulas) // also tests usage of the stand-alone @JoinFormula annotation (i.e. not wrapped within @JoinColumnsOrFormulas)
Session s = openSession(); Session s = openSession();

View File

@ -22,21 +22,21 @@
* Boston, MA 02110-1301 USA * Boston, MA 02110-1301 USA
*/ */
package org.hibernate.test.cut; package org.hibernate.test.cut;
import static org.junit.Assert.assertEquals;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.Currency; import java.util.Currency;
import java.util.List; import java.util.List;
import org.junit.Test;
import org.hibernate.Session; import org.hibernate.Session;
import org.hibernate.criterion.Restrictions; import org.hibernate.criterion.Restrictions;
import org.hibernate.dialect.DB2Dialect; import org.hibernate.dialect.DB2Dialect;
import org.hibernate.dialect.HSQLDialect; import org.hibernate.dialect.HSQLDialect;
import org.hibernate.dialect.SybaseASE15Dialect; import org.hibernate.dialect.SybaseASE15Dialect;
import org.hibernate.testing.SkipForDialect; import org.hibernate.testing.SkipForDialect;
import org.hibernate.testing.SkipForDialects;
import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase; import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
/** /**
* @author Gavin King * @author Gavin King
@ -78,7 +78,9 @@ public class CompositeUserTypeTest extends BaseCoreFunctionalTestCase {
} }
@Test @Test
@SkipForDialect( value = {SybaseASE15Dialect.class, DB2Dialect.class}, jiraKey = "HHH-6788,HHH-6867") @SkipForDialects( {
@SkipForDialect ( value = { SybaseASE15Dialect.class }, jiraKey = "HHH-6788" ),
@SkipForDialect ( value = { DB2Dialect.class }, jiraKey = "HHH-6867" ) } )
public void testCustomColumnReadAndWrite() { public void testCustomColumnReadAndWrite() {
Session s = openSession(); Session s = openSession();
org.hibernate.Transaction t = s.beginTransaction(); org.hibernate.Transaction t = s.beginTransaction();