Skip to content

Stripe subs#4

Open
bigfleet wants to merge 10 commits intomasterfrom
stripe-subs
Open

Stripe subs#4
bigfleet wants to merge 10 commits intomasterfrom
stripe-subs

Conversation

@bigfleet
Copy link
Copy Markdown
Member

For the final instructor-led class, we introduce a pull request with some failing specs.

To fix the group slug spec

https://github.com/norman/friendly_id

To fix the group plan specs

The specs, as written, require a migration on group, and a new group factory. Analyze the code, and figure out what the column should be named to write the migration. Then use https://github.com/thoughtbot/factory_girl/blob/master/GETTING_STARTED.md to figure out how to create the new factory.

The migration you write will allow you to conditionally create membership plans. Install the payola gem and review https://github.com/peterkeen/payola/wiki/Subscriptions for integration instructions.

@bigfleet
Copy link
Copy Markdown
Member Author

Also of potential use: https://stripe.com/docs/guides/subscriptions

@bigfleet
Copy link
Copy Markdown
Member Author

Membership plans is going to be a has many. That's why it's an empty check as opposed to a nil. Thanks mat!

Cheers,

Jim

On Jan 20, 2015, at 9:20 PM, Matthew Banbury notifications@github.com wrote:

Not quite understanding why membership_plans column is plural, or what the datatype would be. Could it be an integer and made enumerable in the group model? (for however many plans you decide to make). Something like:

enum membership_plans: [ :silver, :gold, :platinum ]


Reply to this email directly or view it on GitHub.

@batmanbury
Copy link
Copy Markdown

In line 35 of group_spec, have to change be_true to be true due to RSpec 3.0 Expectations.

That, or specify rspec version to something like 2.99 in Gemfile.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants