Skip to content
This repository was archived by the owner on Mar 6, 2019. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[submodule "sources"]
path = sources
url = git@github.com:dwillis/fech-sources.git
path = sources
url = https://github.com/dwillis/fech-sources.git
39 changes: 22 additions & 17 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,30 @@ PATH
GEM
remote: http://rubygems.org/
specs:
byebug (4.0.4)
columnize (= 0.9.0)
columnize (0.9.0)
diff-lcs (1.2.5)
byebug (10.0.2)
diff-lcs (1.3)
ensure-encoding (0.1)
fastercsv (1.5.5)
mocha (0.9.12)
metaclass (0.0.4)
mocha (1.7.0)
metaclass (~> 0.0.1)
people (0.2.1)
rake (0.8.7)
rdoc (3.9.2)
rspec (2.99.0)
rspec-core (~> 2.99.0)
rspec-expectations (~> 2.99.0)
rspec-mocks (~> 2.99.0)
rspec-core (2.99.2)
rspec-expectations (2.99.2)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.99.3)
yard (0.8.7.6)
rake (12.3.1)
rdoc (6.0.4)
rspec (3.8.0)
rspec-core (~> 3.8.0)
rspec-expectations (~> 3.8.0)
rspec-mocks (~> 3.8.0)
rspec-core (3.8.0)
rspec-support (~> 3.8.0)
rspec-expectations (3.8.1)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.8.0)
rspec-mocks (3.8.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.8.0)
rspec-support (3.8.0)
yard (0.9.16)

PLATFORMS
ruby
Expand All @@ -43,4 +48,4 @@ DEPENDENCIES
yard

BUNDLED WITH
1.10.6
1.16.0
9 changes: 5 additions & 4 deletions README.rdoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

Fech makes it easy to parse electronic campaign finance filings[http://www.fec.gov/finance/disclosure/efile_search.shtml] by candidates, parties and political action committees from the Federal Election Commission. It lets you access filing attributes the same way regardless of filing version, and works as a framework for cleaning and filing data. Fech is an open source project of The New York Times, but contributions from anyone interested in working with F.E.C. filings are greatly appreciated.

Latest version: 1.8. For details see the CHANGELOG.
Latest version: 1.8.1. For details see the CHANGELOG.

Fech works best under Ruby version 2.x, and has been tested under Ruby versions 1.8.7, 1.9.2, 1.9.3, 2.1.2, 2.2.2 and Rubinius.

Expand All @@ -16,6 +16,7 @@ Can be found at Fech's Github page[http://nytimes.github.com/Fech/].

== News

* March 1, 2019: Version 1.8.1 released. Added support for F4T mappings.
* August 19, 2015: Version 1.8 released. Replaced `sources` directory with submodule pulling from [fech-sources](https://github.com/dwillis/fech-sources).
* March 28, 2015: Version 1.7 released. Added support for Schedule SA3L and F3Z transactions, fixed some bugs and updated gems and specs.
* March 11, 2014: Version 1.6.4 released. Bugfix for Schedule E transactions to fix office state and district.
Expand Down Expand Up @@ -57,7 +58,7 @@ Install Fech as a gem:

gem install fech

For use in a Rails 3 application, put the following in your Gemfile:
For use in a Rails 3/4 application, put the following in your Gemfile:

gem 'fech'

Expand Down Expand Up @@ -90,7 +91,7 @@ Evan Carmi, evan@ecarmi.org

Aaron Bycoffe, bycoffe@huffingtonpost.com

Derek Willis, dwillis@nytimes.com
Derek Willis, derek.willis@propublica.org

Daniel Pritchett, daniel@sharingatwork.com

Expand All @@ -100,4 +101,4 @@ Jack Gillum, jgillum@ap.org

== Copyright

Copyright (c) 2013 The New York Times Company. See LICENSE for details.
Copyright (c) 2019 The New York Times Company. See LICENSE for details.
4 changes: 2 additions & 2 deletions lib/fech.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require 'fech/filing'
require 'fech/senate_filing'
require 'fech/rendered_maps'
require 'fech/mappings'
require 'fech/mappings'
require 'fech/default_translations'
require 'fech/translator'
require 'fech/mapped'
Expand All @@ -13,5 +13,5 @@

module Fech
extend FechUtils
DEFAULT_VERSION = "8.1"
DEFAULT_VERSION = "8.3"
end
4 changes: 3 additions & 1 deletion lib/fech/fech_utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ module FechUtils
:f3ps => /^f3ps/i,
:f3x => /(^f3x$)|(^f3x[ant])/i,
:f3z => /^f3z[t]/i,
:f4 => /^f4[na]/i,
:f3z1 => /^f3z1/i,
:f3z2 => /^f3z2/i,
:f4 => /^f4[n|a|t]/i,
:f5 => /^f5[na]/i,
:f56 => /^f56/i,
:f57 => /^f57/i,
Expand Down
2 changes: 1 addition & 1 deletion lib/fech/filing.rb
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ def file_path

# The raw contents of the Filing
def file_contents
File.open(file_path, 'r')
File.open(file_path, "r:#{@encoding}")
end

# Determine the form type of the filing
Expand Down
6 changes: 4 additions & 2 deletions lib/fech/map_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ class MapGenerator
PAPER_FILING_VERSIONS = ["3.1", "3.0", "2.6", "2.4", "2.3", "2.2", "1.0"]
PAPER_BASE_ROW_TYPES = ["HDR", "F3", "F3X", "SchA", "SchB"]

FILING_VERSIONS = ["8.0", "7.0", "6.4", "6.3", "6.2", "6.1",
FILING_VERSIONS = ["8.3", "8.2", "8.1", "8.0", "7.0", "6.4", "6.3", "6.2", "6.1",
"5.3", "5.2", "5.1", "5.0", "3"]
BASE_ROW_TYPES = ["HDR", "F1", "F13", "F132", "F133", "F1M", "F1S", "F2", "F24", "F3", "F3L", "F3P", "F3P31", "F3PS",
"F3S", "F3X", "F3Z", "F4", "F5", "F56", "F57", "F6", "F65", "F7", "F76", "F9", "F91", "F92", "F93",
"F3S", "F3X", "F3Z", "F3Z1", "F3Z2", "F4", "F5", "F56", "F57", "F6", "F65", "F7", "F76", "F9", "F91", "F92", "F93",
"F94", "F99", "H1", "H2", "H3", "H4", "H5", "H6",
"SchA", "SchA3L", "SchB", "SchC", "SchC1", "SchC2", "SchD", "SchE", "SchF", "SchL", "TEXT"]
ROW_TYPE_MATCHERS = {
Expand All @@ -34,6 +34,8 @@ class MapGenerator
"F3PS" => FechUtils::ROW_TYPES[:f3ps],
"F3X" => FechUtils::ROW_TYPES[:f3x],
"F3Z" => FechUtils::ROW_TYPES[:f3z],
"F3Z1" => FechUtils::ROW_TYPES[:f3z1],
"F3Z2" => FechUtils::ROW_TYPES[:f3z2],
"F4" => FechUtils::ROW_TYPES[:f4],
"F5" => FechUtils::ROW_TYPES[:f5],
"F56" => FechUtils::ROW_TYPES[:f56],
Expand Down
103 changes: 55 additions & 48 deletions lib/fech/rendered_maps.rb

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion lib/fech/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module Fech
VERSION = "1.8"
VERSION = "1.8.1"
end
2 changes: 1 addition & 1 deletion sources
Submodule sources updated 52 files
+1 −1 F1.csv
+1 −1 F13.csv
+1 −1 F132.csv
+1 −1 F133.csv
+1 −1 F1M.csv
+1 −1 F1S.csv
+1 −1 F2.csv
+1 −1 F24.csv
+1 −1 F3.csv
+1 −1 F3L.csv
+1 −1 F3P.csv
+1 −1 F3P31.csv
+1 −1 F3PS.csv
+4 −4 F3PZ1.csv
+4 −4 F3PZ2.csv
+1 −1 F3S.csv
+1 −1 F3X.csv
+1 −1 F3Z.csv
+1 −1 F3Z1.csv
+1 −1 F3Z2.csv
+1 −1 F4.csv
+1 −1 F5.csv
+1 −1 F56.csv
+1 −1 F57.csv
+1 −1 F6.csv
+1 −1 F65.csv
+1 −1 F7.csv
+1 −1 F76.csv
+47 −1 F9.csv
+1 −1 F91.csv
+1 −1 F92.csv
+1 −1 F93.csv
+1 −1 F94.csv
+1 −1 F99.csv
+1 −1 H1.csv
+1 −1 H2.csv
+1 −1 H3.csv
+1 −1 H4.csv
+1 −1 H5.csv
+1 −1 H6.csv
+1 −1 SchA.csv
+1 −1 SchA3L.csv
+1 −1 SchB.csv
+1 −1 SchC.csv
+1 −1 SchC1.csv
+1 −1 SchC2.csv
+1 −1 SchD.csv
+1 −1 SchE.csv
+1 −1 SchF.csv
+1 −1 SchL.csv
+1 −1 TEXT.csv
+48 −0 headers/8.3.csv
58 changes: 58 additions & 0 deletions spec/data/1247604.fec
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
HDRFEC8.2FECfile8.2.0.0(f31)
F3NC00670364Friends of Susan BoserP.O.�Box 2056IndianaPA15701PA15Q22018042620180630BradyDavidMr.2018071519909.080.0019909.0835056.580.0035056.582801.190.0020500.0010047.916555.0316602.940.00591.492714.6519909.080.006500.000.006500.000.000.0026409.0835056.580.000.000.000.000.000.000.000.000.0035056.5811448.6926409.0837857.7735056.582801.1922904.830.0022904.8344376.830.0044376.8311557.378041.3219598.690.00591.492714.6522904.830.0020500.000.0020500.000.000.0043404.8344376.830.000.000.000.000.000.000.000.000.0044376.83
SA11AIC00670364SA11AI.4279INDAaronRoger339 Liberty StreetFranklinPA16323G201820180522250.00250.00Check received by mailUnknownUnknown
SA11AIC00670364SA11AI.4291INDArmbrustGary225 Heasley Hollow RoadVandergriftPA15690P201820180510150.00300.00Check received by mailSelfAttorney
SA11AIC00670364SA11AI.4532CANBoserBoserLMrs.830 White Farm RdIndianaPA15701G2018201806301078.0124292.66In-kind - Car Expenses - IRS rate @$0.55Pennsylvania State Higher EdProfessorH8PA09065BoserBoserLMrs.HPA15
SA11AIC00670364SA11AI.4266INDBradwickFaye634 Willow AveIndianaPA15701P201820180429300.00400.00Check received at house partyRetiredRetired
SA11AIC00670364SA11AI.4351INDBradyDavidMr.830 White Farm RdIndianaPA15701P20182018051550.001059.46In-kind - Snacks fo Election NightWescoDir Supply Chain
SA11AIC00670364SA11AI.4353INDBradyDavidMr.830 White Farm RdIndianaPA15701G20182018051620.271079.73In-kind - Facebook adWescoDir Supply Chain
SA11AIC00670364SA11AI.4411INDBradyDavidMr.830 White Farm RdIndianaPA15701G201820180608250.261329.99In-kind - WIX Email AccuntsWescoDir Supply Chain
SA11AIC00670364SA11AI.4412INDBradyDavidMr.830 White Farm RdIndianaPA15701G20182018061224.991354.98In-kind - Facebook AdWescoDir Supply Chain
SA11AIC00670364SA11AI.4413INDBradyDavidMr.830 White Farm RdIndianaPA15701G20182018061516.381371.36In-kind - Facebook AdWescoDir Supply Chain
SA11AIC00670364SA11AI.4465INDBrownMargaret106 Sumar Rd.St. Mary'sPA15857G201820180626500.00500.00ACT BlueUniversity of PittsburghProfessor
SA11AIC00670364SA11AI.4467INDBrownMargaret106 Sumar Rd.St. Mary'sPA15857G201820180626500.001000.00ACT BlueUniversity of PittsburghProfessor
SA11AIC00670364SA11AI.4330INDFeldmanLarry649 Shryock Ave.IndianaPA15701G201820180520200.00250.00Act BlueRetiredRetired
SA11AIC00670364SA11AI.4461INDHartleyHarold60 Stonehedge CircleBrookvillePA15825G201820180624250.00250.00ACT BlueRetiredRetired
SA11AIC00670364SA11AI.4447INDIntemannGerald453 Cheese Run RoadIndianaPA15701G201820180617100.00250.00ACT BlueRetiredRetired
SA11AIC00670364SA11AI.4254INDKlainMatthew1795 Barkley RdClarksburgPA15725P201820180428250.00250.00Check from home eventIRMCPhysician
SA11AIC00670364SA11AI.4456INDLongStacy1900 Mumau RoadGlenn CampbellPA15742G201820180626208.00208.00In-kind - Graphic Design - LogoCats Up GraphicsOwner
SA11AIC00670364SA11AI.4430INDPerlowCharles310 Grant StreetSuite 2500PittsburghPA15219G2018201806181000.001000.00Check received from CallsMcKnight Reality PartnersLawyer
SA11AIC00670364SA11AI.4420INDRoseJonathan33 Katonah AveKatonahNY10536G2018201806012500.002500.00Check ReceivedSelfProperty Devleopment
SA11AIC00670364SA11AI.4310INDSteelmanSarah220 N 6th StIndianaPA15701P201820180508500.00500.00Act BlueRetiredNone
SA11AIC00670364SA11AI.4328INDSuttieJill988 Creston RoadBerkleyCA94708G201820180518250.00250.00Act BlueSelfWriter/editor
SA11AIC00670364SA11AI.4444INDWheatleySusan1107 ray roadPenn RunPA15765G201820180616150.00250.00ACT BlueRetiredRetired
SA11AIC00670364SA11AI.4497INDWheelerSarah870 Harvest LaneIndianaPA15701G201820180617500.00500.00Check ReceivedRetiredRetired
SA11AIC00670364SA11AI.4432INDWilcoxMichel1172 Old Route 322CochrantonoPA16314G2018201806211000.001000.00Check received at Oil Region Rising eventRetiredRetired
SA11CC00670364SA11C.4357PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G2018201805233.373.37Check Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4359PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G201820180523136.66140.03Check Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4360PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G20182018052316.70156.73Check Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4361PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G2018201805230.92157.65Check Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4362PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G201820180523406.54564.19Check Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4524PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G2018201806047.93572.12Received by MailC00630012It Starts Today
SA11CC00670364SA11C.4422PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G20182018061112.78584.90Check ReceiptC00630012It Starts Today
SA11CC00670364SA11C.4523PACIt Starts Today237 Florida Avenue NWWashingtonDC20001G2018201806186.59591.49Received by MailC00630012It Starts Today
SA11DC00670364SA11D.4364CANBoserBoserLMrs.830 White Farm RdIndianaPA15701G2018201805312714.6523214.65In-kind - Mileage at IRS rate for campaign travelPennsylvania State Higher EdProfessorH8PA09065BoserBoserLMrs.HPA15
SA13AC00670364SA13A.4349CANBoserBoserLMrs.830 White Farm RdIndianaPA15701P2018201805022500.0016500.00Personal LoanPennsylvania State Higher EdProfessorH8PA09065BoserBoserLMrs.HPA15
SA13AC00670364SA13A.4350CANBoserBoserLMrs.830 White Farm RdIndianaPA15701P2018201805034000.0020500.00Personal LoanPennsylvania State Higher EdProfessorH8PA09065BoserBoserLMrs.HPA15
SB17C00670364SB17.4196ORGAmpersand Consulting4105 Penn AvenuePittsburghPA15224P2018201804277740.00Mail Piece preparation001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4201ORGAmpersand Consulting4105 Penn AvenuePittsburghPA15224P2018201805026824.62Postage - Mail piece004C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4202ORGAmpersand Consulting4105 Penn AvenuePittsburghPA15224P2018201805033950.00Radio Advertising - Creation and Airtime004C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4437ORGAmpersand Consulting4105 Penn AvenuePittsburghPA15224G2018201806056000.00Payment for Fund Raising Consulting003C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4365CANBoserBoserLMrs.830 White Farm RdIndianaPA15701G2018201805312714.65In-kind - Mileage at IRS rate for campaign travelH8PA09065HPA15
SB17C00670364SB17.4533CANBoserBoserLMrs.830 White Farm RdIndianaPA15701G2018201806301078.01In-kind - Car Expenses - IRS rate @$0.55H8PA09065HPA15
SB17C00670364SB17.4416INDBradyDavidMr.830 White Farm RdIndianaPA15701G201820180608250.26In-kind - WIX Email Accunts
SB17C00670364SB17.4415INDBradyDavidMr.830 White Farm RdIndianaPA15701G20182018061224.99In-kind - Facebook Ad
SB17C00670364SB17.4414INDBradyDavidMr.830 White Farm RdIndianaPA15701G20182018061516.38In-kind - Facebook Ad
SB17C00670364SB17.4199INDCampbellCallie123 Charles DriveCamillusNY13031P201820180429210.00Campaign Work Various001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4206INDCampbellCallie123 Charles DriveCamillusNY13031P201820180518160.00Campaign Work001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4204INDGuerraChelsea104 Greenview DriveIndianaPA15701P201820180515250.00Campaign Work001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4205INDHorvathElliePO Box 2Tire HillPA15959P201820180515840.00Campaign Work001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4458INDLongStacy1900 Mumau RoadGlenn CampbellPA15742G201820180626208.00In-kind - Graphic Design - Logo
SB17C00670364SB17.4203ORGPrint and Copy Center731 Allegheny BlvdIndianaPA15701P201820180503179.76Printing004C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4409ORGPrint and Copy Center731 Allegheny BlvdIndianaPA15701G201820180611873.12Literature and Buttons004C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4207INDStenmanAmber415 Pearl StPittsburghPA15224P2018201805261600.00Campaign Work - Labor001C00670364Friends of Susan BoserHPA15
SB17C00670364SB17.4496INDStenmanAmber415 Pearl StPittsburghPA15224G2018201806291516.67Campaign Manager - Contract Rate001C00670364Friends of Susan BoserHPA15
SC/10C00670364SC/10.424513ACANBoserBoserLMrs.830 White Farm RdIndianaPA15701P20182000.000.002000.002018042112/31/20180.0000NYH8PA09065BoserBoserLMrs.HPA15
SC/10C00670364SC/10.424713ACANBoserBoserLMrs.830 White Farm RdIndianaPA15701P201812000.000.0012000.002018042512/31/20180.0000NYH8PA09065BoserBoserLMrs.HPA15
SC/10C00670364SC/10.434913ACANBoserBoserLMrs.830 White Farm RdIndianaPA15701P20182500.000.002500.002018050212/31/20180.0000NYH8PA09065BoserBoserLMrs.HPA15
SC/10C00670364SC/10.435013ACANBoserBoserLMrs.830 White Farm RdIndianaPA15701P20184000.000.004000.002018050312/31/20180.0000NYH8PA09065BoserBoserLMrs.HPA15
3 changes: 3 additions & 0 deletions spec/filing_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
@filing_special_character.stubs(:file_path).returns(File.join(File.dirname(__FILE__), 'data', '771694.fec'))
@filing_f99 = Fech::Filing.new(862554)
@filing_f99.stubs(:file_path).returns(File.join(File.dirname(__FILE__), 'data', '862554.fec'))
@filing_encoding = Fech::Filing.new(1247604)
@filing_encoding.stubs(:file_path).returns(File.join(File.dirname(__FILE__), 'data', '1247604.fec'))
end

describe "#filing_version" do
Expand Down Expand Up @@ -83,6 +85,7 @@
sum_f13[:form_type].should == 'F13N'
sum_filing_special_character = @filing_special_character.summary
sum_filing_special_character[:form_type].should == "F3XN"
expect{@filing_encoding.summary}.to_not raise_error
end
end

Expand Down
8 changes: 4 additions & 4 deletions spec/mappings_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
end

it "should return the correct row_map" do
@mappings.for_row("sa").should == @mappings.map["^sa"]["^8.1|8.0"]
@mappings.for_row("sa").should == @mappings.map["^sa"]["^8.3|8.2|8.1|8.0"]
@mappings.for_row("f3p31").should_not == @mappings.for_row("f3p")
end

it "should use a greedy match on the row type, matching most complete available option" do
@mappings.for_row("f3p31").should == @mappings.map[FechUtils::ROW_TYPES[:f3p31].source]["^8.1|8.0|7.0|6.4|6.3|6.2|6.1"]
@mappings.for_row("f3p").should == @mappings.map[FechUtils::ROW_TYPES[:f3p].source]["^8.1|8.0|7.0"]
@mappings.for_row("f3p31").should == @mappings.map[FechUtils::ROW_TYPES[:f3p31].source]["^8.3|8.2|8.1|8.0|7.0|6.4|6.3|6.2|6.1"]
@mappings.for_row("f3p").should == @mappings.map[FechUtils::ROW_TYPES[:f3p].source]["^8.3|8.2|8.1|8.0|7.0"]
end

end
Expand Down Expand Up @@ -43,4 +43,4 @@

end

end
end
19 changes: 9 additions & 10 deletions tasks/fech.rake
Original file line number Diff line number Diff line change
@@ -1,41 +1,40 @@
require 'fech'
require 'rspec'
require 'rspec/core/rake_task'

namespace :fech do

desc "Recreate the column header maps from source .csv files"
task :maps do
# This will spit out a rendered mappings file, but will not be loaded by
# the gem by default. To use the new file, move it into the lib/fech
# folder of your active Fech gem.
source = 'sources/'
destination = ENV['destination'] || Dir.pwd

if File.directory?(destination)
destination = File.join(destination, 'rendered_maps.rb')
end

Fech::MapGenerator.convert_header_file_to_row_files(source)
Fech::MapGenerator.dump_row_maps_to_ruby(source, destination)

puts "Successfully wrote out mappings to #{destination}"
end

namespace :test do

desc "Run all specs."
RSpec::Core::RakeTask.new(:spec) do |t|
t.pattern = 'spec/*_spec.rb'
t.verbose = false
end

RSpec::Core::RakeTask.new(:coverage) do |t|
t.rcov = true
t.rcov_opts = %w{--exclude gems\/,spec\/,features\/,seeds\/ --sort coverage}
t.verbose = true
end

end

end