-
Notifications
You must be signed in to change notification settings - Fork 166
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added tests (Currently failing so @ignored) that address issues with …
- Loading branch information
Showing
12 changed files
with
355 additions
and
117 deletions.
There are no files selected for viewing
30 changes: 30 additions & 0 deletions
30
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/edges/BaseEdge.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,30 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.edges; | ||
|
||
import org.neo4j.ogm.annotation.EndNode; | ||
import org.neo4j.ogm.annotation.GraphId; | ||
import org.neo4j.ogm.annotation.StartNode; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.BaseNode; | ||
|
||
public abstract class BaseEdge<T extends BaseNode, U extends BaseNode> { | ||
|
||
@GraphId | ||
public Long relationshipId; | ||
|
||
public String title; | ||
|
||
@StartNode | ||
public T start; | ||
|
||
@EndNode | ||
public U end; | ||
|
||
public BaseEdge() { | ||
|
||
} | ||
|
||
public BaseEdge(T start, U end, String title) { | ||
this.start = start; | ||
this.end = end; | ||
this.title = title; | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/edges/LastDrama.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,17 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.edges; | ||
|
||
import org.neo4j.ogm.annotation.RelationshipEntity; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.Drama; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.StageActor; | ||
|
||
@RelationshipEntity(type="LAST_APPEARENCE") | ||
public class LastDrama extends BaseEdge<StageActor, Drama>{ | ||
|
||
public LastDrama() { | ||
super(); | ||
} | ||
|
||
public LastDrama(StageActor start, Drama end, String title) { | ||
super(start, end, title); | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/edges/LastMovie.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,17 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.edges; | ||
|
||
import org.neo4j.ogm.annotation.RelationshipEntity; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.FilmActor; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.Movie; | ||
|
||
@RelationshipEntity(type="LAST_APPEARENCE") | ||
public class LastMovie extends BaseEdge<FilmActor, Movie>{ | ||
|
||
public LastMovie() { | ||
super(); | ||
} | ||
|
||
public LastMovie(FilmActor start, Movie end, String title) { | ||
super(start, end, title); | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/edges/PlayedInDrama.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,18 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.edges; | ||
|
||
import org.neo4j.ogm.annotation.RelationshipEntity; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.Drama; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.StageActor; | ||
|
||
@RelationshipEntity(type="PLAYED_IN") | ||
public class PlayedInDrama extends BaseEdge<StageActor, Drama>{ | ||
|
||
public PlayedInDrama() { | ||
super(); | ||
} | ||
|
||
public PlayedInDrama(StageActor start, Drama end, String title) { | ||
super(start, end, title); | ||
} | ||
|
||
} |
18 changes: 18 additions & 0 deletions
18
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/edges/PlayedInMovie.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,18 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.edges; | ||
|
||
import org.neo4j.ogm.annotation.RelationshipEntity; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.FilmActor; | ||
import org.neo4j.ogm.persistence.examples.stage.nodes.Movie; | ||
|
||
@RelationshipEntity(type="PLAYED_IN") | ||
public class PlayedInMovie extends BaseEdge<FilmActor, Movie>{ | ||
|
||
public PlayedInMovie() { | ||
super(); | ||
} | ||
|
||
public PlayedInMovie(FilmActor start, Movie end, String title) { | ||
super(start, end, title); | ||
} | ||
|
||
} |
22 changes: 22 additions & 0 deletions
22
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/nodes/BaseNode.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,22 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.nodes; | ||
|
||
import org.neo4j.ogm.annotation.GraphId; | ||
import org.neo4j.ogm.annotation.NodeEntity; | ||
|
||
@NodeEntity | ||
public class BaseNode { | ||
|
||
@GraphId | ||
public Long id; | ||
|
||
public String title; | ||
|
||
public BaseNode() { | ||
|
||
} | ||
|
||
public BaseNode(String title) { | ||
this.title = title; | ||
} | ||
|
||
} |
16 changes: 16 additions & 0 deletions
16
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/nodes/Drama.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,16 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.nodes; | ||
|
||
import org.neo4j.ogm.annotation.NodeEntity; | ||
|
||
@NodeEntity | ||
public class Drama extends BaseNode { | ||
|
||
public Drama() { | ||
super(); | ||
} | ||
|
||
public Drama(String title) { | ||
super(title); | ||
} | ||
|
||
} |
28 changes: 28 additions & 0 deletions
28
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/nodes/FilmActor.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,28 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.nodes; | ||
|
||
|
||
import java.util.HashSet; | ||
import java.util.Set; | ||
|
||
import org.neo4j.ogm.annotation.NodeEntity; | ||
import org.neo4j.ogm.annotation.Relationship; | ||
import org.neo4j.ogm.persistence.examples.stage.edges.LastMovie; | ||
import org.neo4j.ogm.persistence.examples.stage.edges.PlayedInMovie; | ||
|
||
@NodeEntity | ||
public class FilmActor extends BaseNode { | ||
public FilmActor(){ | ||
super(); | ||
} | ||
public FilmActor(String title){ | ||
super(title); | ||
} | ||
|
||
@Relationship(type="PLAYED_IN") | ||
public Set<PlayedInMovie> movies = new HashSet<>(); | ||
|
||
@Relationship(type = "LAST_APPEARENCE") | ||
public LastMovie lastMovie; | ||
|
||
|
||
} |
15 changes: 15 additions & 0 deletions
15
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/nodes/Movie.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,15 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.nodes; | ||
|
||
import org.neo4j.ogm.annotation.NodeEntity; | ||
|
||
@NodeEntity | ||
public class Movie extends BaseNode { | ||
|
||
public Movie() { | ||
super(); | ||
} | ||
|
||
public Movie(String title) { | ||
super(title); | ||
} | ||
} |
22 changes: 22 additions & 0 deletions
22
core/src/test/java/org/neo4j/ogm/persistence/examples/stage/nodes/StageActor.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,22 @@ | ||
package org.neo4j.ogm.persistence.examples.stage.nodes; | ||
|
||
import java.util.HashSet; | ||
import java.util.Set; | ||
|
||
import org.neo4j.ogm.annotation.NodeEntity; | ||
import org.neo4j.ogm.annotation.Relationship; | ||
import org.neo4j.ogm.persistence.examples.stage.edges.LastDrama; | ||
import org.neo4j.ogm.persistence.examples.stage.edges.PlayedInDrama; | ||
|
||
@NodeEntity | ||
public class StageActor extends BaseNode { | ||
public StageActor() { super(); } | ||
public StageActor(String title) { super(title); } | ||
|
||
@Relationship(type="PLAYED_IN") | ||
public Set<PlayedInDrama> dramas = new HashSet<>(); | ||
|
||
@Relationship(type = "LAST_APPEARENCE") | ||
public LastDrama lastDrama; | ||
|
||
} |
117 changes: 0 additions & 117 deletions
117
...rc/test/java/org/neo4j/ogm/persistence/model/AbstractWithGenericPropertyRelationship.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.