Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Better support for QuerySupertype #565
- Loading branch information
Showing
5 changed files
with
52 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
querydsl-apt/src/test/java/com/mysema/query/domain/QuerySuperTypeTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package com.mysema.query.domain; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import java.util.Set; | ||
|
||
import javax.jdo.annotations.PersistenceCapable; | ||
|
||
import org.junit.Test; | ||
|
||
import com.mysema.query.annotations.QuerySupertype; | ||
|
||
public class QuerySuperTypeTest { | ||
|
||
@QuerySupertype | ||
public static class Supertype { | ||
|
||
} | ||
|
||
@PersistenceCapable | ||
public static class JdoEntity { | ||
Set<Supertype> references; | ||
} | ||
|
||
@Test | ||
public void JdoEntity() { | ||
assertEquals(QQuerySuperTypeTest_Supertype.class, | ||
QQuerySuperTypeTest_JdoEntity.jdoEntity.references.any().getClass()); | ||
} | ||
|
||
} |