Skip to content

Parking is a simple Java software built using TDD.

Notifications You must be signed in to change notification settings

patrickreinan/parking

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Parking

Parking is a simple Java software built using TDD. We are using test-first method to add or change features. We want ensure that all the business rules are covered before implement software details (database, web, ui, etc).

Requirements

  • Java
  • Clean Code
  • SOLID principles
  • Domain-Driven Design
  • KISS
  • YAGNI

Phases

This project is being built in 3 phases:

  • Phase 1 - Build domain layer and its unit tests.
  • Phase 2 - Build application layer and tests.
  • Phase 3 - Build infrastructure, integration and end-to-end (e2e) tests.

Scenario

A parking can have different pricing according how much time car stay parked in. Pricing is defined by time periods and these time periods can be combined. So we are considering just 2 rules:

Pricing Type 1:

  • Period until 1 hour: price is $1
  • Period until 2 hours: price is $2
  • Period until 12 hours: price is $10
  • After 12 hours the price is added in $10 daily

Example:

  • 3 hours: price is $10
  • 14 hours: price is $20
  • 3 days: price is $40

Pricing Type 2:

  • Each hour has a fixed price ($5)

Example:

  • 3 hours: price is $15
  • 10 hours: price is $50

Solution

A application to simulate pricing.

About

Parking is a simple Java software built using TDD.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages