Skip to content
This repository has been archived by the owner on Dec 19, 2019. It is now read-only.

Commit

Permalink
added test for normalize trial stats
Browse files Browse the repository at this point in the history
  • Loading branch information
jhliberty committed Dec 3, 2011
1 parent 4383f3b commit 1b6dcc9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Gemfile.lock
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
paypal-recurring (0.1.6)
paypal-recurring (0.1.7)

GEM
remote: http://rubygems.org/
Expand Down
6 changes: 6 additions & 0 deletions spec/paypal/request_spec.rb
Expand Up @@ -83,6 +83,12 @@
subject.normalize_params(:period => :yearly).should == {:BILLINGPERIOD => "Year"}
end

it "normalizes trial period" do
subject.normalize_params(:trial_period => :monthly).should == {:TRIALBILLINGPERIOD => "Month"}
subject.normalize_params(:trial_period => :daily).should == {:TRIALBILLINGPERIOD => "Day"}
subject.normalize_params(:trial_period => :yearly).should == {:TRIALBILLINGPERIOD => "Year"}
end

it "normalizes start at" do
date = Time.parse("2011-06-26 15:13:00")
subject.normalize_params(:start_at => date).should == {:PROFILESTARTDATE => "2011-06-26T15:13:00Z"}
Expand Down

0 comments on commit 1b6dcc9

Please sign in to comment.