use of com.querydsl.core.testutil.ExcludeIn in project querydsl by querydsl.
the class HibernateSQLBase method entityQueries_createQuery2.
@Test
@ExcludeIn(Target.MYSQL)
public void entityQueries_createQuery2() {
SAnimal cat = new SAnimal("CAT");
QCat catEntity = QCat.cat;
Query query = query().from(cat).select(catEntity).createQuery();
assertEquals(6, query.list().size());
}
use of com.querydsl.core.testutil.ExcludeIn in project querydsl by querydsl.
the class TargetRule method isExecuted.
private boolean isExecuted(Description description, Target target) {
ExcludeIn ex = description.getAnnotation(ExcludeIn.class);
// excluded in given targets
if (ex != null && Arrays.asList(ex.value()).contains(target)) {
return false;
}
// included only in given targets
IncludeIn in = description.getAnnotation(IncludeIn.class);
if (in != null && !Arrays.asList(in.value()).contains(target)) {
return false;
}
return true;
}
use of com.querydsl.core.testutil.ExcludeIn in project querydsl by querydsl.
the class SpatialBase method geometryType.
// FIXME, maybe use enum as the type ?!?
@Test
@ExcludeIn(H2)
public void geometryType() {
List<Tuple> results = query().from(shapes).select(shapes.geometry, shapes.geometry.geometryType()).fetch();
assertFalse(results.isEmpty());
for (Tuple row : results) {
assertEquals(normalize(row.get(shapes.geometry).getGeometryType().name()), normalize(row.get(shapes.geometry.geometryType())));
}
}
use of com.querydsl.core.testutil.ExcludeIn in project querydsl by querydsl.
the class SpatialBase method point_x_y.
@Test
@ExcludeIn(H2)
public void point_x_y() {
PointPath<Point> point = shapes.geometry.asPoint();
List<Tuple> results = withPoints().select(point, point.x(), point.y()).fetch();
assertFalse(results.isEmpty());
for (Tuple row : results) {
assertEquals(Double.valueOf(row.get(point).getX()), row.get(point.x()));
assertEquals(Double.valueOf(row.get(point).getY()), row.get(point.y()));
}
}
use of com.querydsl.core.testutil.ExcludeIn in project querydsl by querydsl.
the class MergeBase method merge_with_keys_Null_Id.
@Test
@ExcludeIn({ CUBRID, DB2, DERBY, POSTGRESQL, SQLSERVER, TERADATA })
public void merge_with_keys_Null_Id() throws SQLException {
ResultSet rs = merge(survey).keys(survey.id).setNull(survey.id).set(survey.name, "Hello World").executeWithKeys();
assertTrue(rs.next());
assertTrue(rs.getObject(1) != null);
rs.close();
}
Aggregations