mirror of https://github.com/apache/openjpa.git
Change TestId class name to IdTestClass to avoid JUnit 4 detects TestId is a test case and generates "java.lang.Exception: No runnable methods" failures.
git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@1359936 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
1246de0774
commit
b5c83f05f9
|
@ -23,13 +23,13 @@ import javax.persistence.Id;
|
||||||
import javax.persistence.IdClass;
|
import javax.persistence.IdClass;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A persistent class using a {@link TestId separate class} as its primary identifier.
|
* A persistent class using a {@link IdTestClass separate class} as its primary identifier.
|
||||||
*
|
*
|
||||||
* @author Pinaki Poddar
|
* @author Pinaki Poddar
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
@Entity
|
@Entity
|
||||||
@IdClass(TestId.class)
|
@IdClass(IdTestClass.class)
|
||||||
public class EntityWithIdClass {
|
public class EntityWithIdClass {
|
||||||
@Id
|
@Id
|
||||||
private String name;
|
private String name;
|
||||||
|
|
|
@ -31,7 +31,7 @@ package org.apache.openjpa.persistence.criteria;
|
||||||
* @author Pinaki Poddar
|
* @author Pinaki Poddar
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TestId {
|
public class IdTestClass {
|
||||||
String name;
|
String name;
|
||||||
long ssn;
|
long ssn;
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ public class TestId {
|
||||||
return false;
|
return false;
|
||||||
if (getClass() != obj.getClass())
|
if (getClass() != obj.getClass())
|
||||||
return false;
|
return false;
|
||||||
TestId other = (TestId) obj;
|
IdTestClass other = (IdTestClass) obj;
|
||||||
if (name == null) {
|
if (name == null) {
|
||||||
if (other.name != null)
|
if (other.name != null)
|
||||||
return false;
|
return false;
|
Loading…
Reference in New Issue