Movie extends BaseEntity { public boolean isEmptyRating() { return getRating() == null; } Movie(String title, int year);  Movie(Movie movie); boolean isEmptyTitle(); boolean isEmptyYear(); boolean isDefaultType(); boolean isEmptyIMDBId(); boolean isEmptyRating();  }
@Test public void testIsEmptyRating() throws Exception { assertFalse(new Movie("Inception", 2010).setRating(10).isEmptyRating()); assertTrue(new Movie("Inception", 2010).setRating(null).isEmptyRating()); }