Last active
March 29, 2016 04:52
-
-
Save cosbor11/ade2259ecb18a944e3c8 to your computer and use it in GitHub Desktop.
The episodes should not be null and they are lazily loaded
This file contains hidden or 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
| // Assert the episodes are lazily loaded | |
| firstSeason = theSopranosCopy.seasons.get(0); | |
| assertNotNull("The first seasons' episodes should not be null since it is lazily loaded", firstSeason.episodes); | |
| assertTrue("The first seasons' episodes should be LazyRelationshipCollection", (firstSeason.episodes instanceof LazyRelationshipCollection)); | |
| // Notice when I reference an episode it is hydrated | |
| Episode episode = firstSeason.episodes.get(0); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment