Skip to content

alankirk/tech-exercise

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kudocs Tech Exercise

Exercise Intro

In this exercise, you'll see that there is a method in the PhonePlan class that calculates the cost of a plan differently depending on its type. However, the class should only know how to retrieve the cost, not the details of how to calculate it.

Instructions

To start, you'll want to fork this repo and run the setup script

cd tech-exercise
bin/setup

Open up lib/phone_plan.rb. There you will see a single method named cost. Its corresponding tests are in spec/lib/phone_plan_spec.rb.

Make sure all the tests are passing by running:

bundle exec rspec

Send me a link to your fork, you may want to create a PR as this is an opportunity to eloborate on any of the following:

  • Any assumptions you made.
  • What potential problems can you identify with the existing code?
  • What approaches did you consider?
  • How do your changes improve this code?
  • Anything else you feel relevant?

The above will form the basis of a more technical discussion.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 96.8%
  • Shell 3.2%