@Test
	public void canGetProductsByCategory() {
		List<Integer> categories = new ArrayList<>();
		categories.add(CategoryJUnit.getACategory());

		ProductModel addedProduct = ProductModel.builder("Night Visions", 1)
				.description("Imagine Dragons").cost(149).rrp(400)
				.categories(categories).build();

		List<ProductModel> products = null;
		boolean isInResult = false;
		try {
			addedProduct = new ProductModel(insertProduct(addedProduct),
					addedProduct);

			products = pd.getProductsByCategory(addedProduct.getCategories()
					.get(0));

			for (ProductModel product : products) {
				if (addedProduct.equals(product)) {
					isInResult = true;
					break;
				}
			}

			deleteProduct(addedProduct.getId());
		} catch (WebshopAppException e) {
			e.printStackTrace();
		}

		assertTrue(isInResult);

	}