Skip to content

Instantly share code, notes, and snippets.

@FunnyGhost
Created December 5, 2019 10:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save FunnyGhost/c2dab2d40ae5316c76ff6ab8bbdba793 to your computer and use it in GitHub Desktop.
Save FunnyGhost/c2dab2d40ae5316c76ff6ab8bbdba793 to your computer and use it in GitHub Desktop.
it('should show all the favorite movies', () => {
const movieComponents = fixture.debugElement.queryAll(By.directive(FavoriteMovieComponent));
expect(movieComponents.length).toEqual(favoriteMoviesToUse.length);
const movieComponentsInputs = movieComponents.map(
htmlComponent => (htmlComponent.componentInstance as FavoriteMovieComponent).favoriteMovie
);
expect(movieComponentsInputs).toEqual(favoriteMoviesToUse);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment