Skip to content
This repository has been archived by the owner on Feb 23, 2023. It is now read-only.

A test-driven implementation of Ruby Quiz #122: Checking Credit Cards

License

Notifications You must be signed in to change notification settings

paulfioravanti/credit_card_checker

Repository files navigation

Credit Card Checker

Description

This is an attempt at a test-driven implementation of Ruby Quiz #122: Checking Credit Cards

All code is written in pure Ruby, with some help from ActiveModel::Validations for model validation checks and Thor for the command-line interface, and is tested using RSpec.

Installation

Install

$ bundle install

Usage

Run program:

$ bin/credit_card_checker

Testing:

Code quality is attempted by using RSpec for testing, SimpleCov for code test coverage, Reek to fix code smells, as well as Code Climate and Coveralls for quality metrics.

Run tests:

$ rspec spec/

Check test coverage (after running rspec):

$ open coverage/index.html

Check code smells:

$ rake reek

Check quality metrics:

Code Climate Coverage Status

TODOs:

  • Fix that one last code reek...
  • More robust CLI testing and implementation; make handling of bad files fail gracefully, add more options etc.

Social

profile for Paul Fioravanti at Stack Overflow, Q&A for professional and enthusiast programmers

endorse

Copyright

Copyright (c) 2012 Paul Fioravanti

See MIT LICENSE for details.

Bitdeli Badge

About

A test-driven implementation of Ruby Quiz #122: Checking Credit Cards

Topics

Resources

License

Stars

Watchers

Forks

Languages