Created
February 3, 2009 16:25
-
-
Save anonymous/57595 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def new | |
if !user.billing_information | |
user.build_billing_information | |
user.billing_information.first_name = user.first_name | |
user.billing_information.last_name = user.last_name | |
user.billing_information.postal_code = user.profile.postal_code | |
end | |
define_subscription_details | |
end | |
describe "a GET to new without a subscription and without billing information" do | |
before do | |
@user.stub!(:subscription).and_return(nil) | |
@user.stub!(:billing_information).and_return(nil) | |
end | |
it "should get the new subscription page" do | |
get :new | |
response.should be_success | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment