You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
469 B

  1. package de.hs_fulda.ciip.projjpn;
  2. import junit.framework.TestCase;
  3. public class ItemTest extends TestCase {
  4. public void test_ItemNotInStock() {
  5. // Given
  6. Item item = new Item();
  7. // When
  8. boolean notInStock = item.inStock();
  9. // Then
  10. assertFalse(notInStock);
  11. }
  12. public void test_ItemInStock() {
  13. // Given
  14. Item item = new Item();
  15. item.updateAvailability(1);
  16. // When
  17. boolean inStock = item.inStock();
  18. // Then
  19. assertTrue(inStock);
  20. }
  21. }