Created
April 27, 2019 09:11
-
-
Save tbelmega/06cab3b0d21b430493fdc4ba0ce92b2a to your computer and use it in GitHub Desktop.
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
@Test | |
fun `findMostOrderedProducts - 6 orders for 3 products in db - returns Top 2`() { | |
// given | |
// when | |
val foundProducts = productRepository.findMostOrderedProducts(numberOfProducts) | |
// then | |
assertThat(foundProducts).hasSize(numberOfProducts) | |
assertThat(foundProducts).containsExactlyInAnyOrder(product1, product2) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment