Skip to content

serenity-dojo/challenge-1---the-java-fruit-shop-Rithy37

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fruit Shop Cart Calculator Challenge

In this exercise, your challenge is to write a Fruit Shop Cart Calculator. Write tests code to illustrate the following requirements, and write the additional application code you need to make them work:

  • The shop sells apples, oranges, bananas, pears, peaches and other fruit, depending on availability. For example the prices per kilo for the currently available fruit are:
    • Apples: $4.00
    • Oranges: $5.50
    • Bananas: $6.00
    • Pears: $4.50
  • You can update the catalog with the current market price of a fruit
  • The Catalog should list the names of the currently available fruit in alphabetical order
  • The Catalog should report the price of a given type of fruit
  • You can add items to your shopping cart, which should keep a running total.
  • The Catalog should throw a FruitUnavailableException if the fruit is not currently available
  • When you buy 5 kilos or more of any fruit, you get a 10% discount.

You should end up with at least 10 test cases. See the catalog test to get started.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%