-
Notifications
You must be signed in to change notification settings - Fork 268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[wip] Adding creditcard payment #334
Conversation
@@ -0,0 +1,5 @@ | |||
require 'rails_helper' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
|
Yes and yes |
@user_count ||= User.count | ||
end | ||
end | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 trailing blank lines detected.
74d71a7
to
1485436
Compare
1485436
to
88824bc
Compare
email: current_user.email, | ||
quantity: user_count | ||
) | ||
pp customer.instance_methods(false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do not write to stdout. Use Rails' logger if you want to log.
40c248d
to
cd78851
Compare
end | ||
|
||
def costs | ||
enabled? ? @number_of_users * price : 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unnecessary spacing detected.
sign_in_user(user, subdomain: subdomain) | ||
|
||
visit users_url(subdomain: subdomain) | ||
expect(page).not_to have_selector("input[type=submit][value='#{I18n.t("users.de_activate")}']") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line is too long. [101/80]
Prefer single-quoted strings inside interpolations.
bb55534
to
cb280d4
Compare
@@ -44,7 +9,7 @@ class User < ActiveRecord::Base | |||
:confirmable, | |||
:invitable | |||
|
|||
validates_presence_of :first_name, :last_name | |||
validates_presence_of :first_name, :last_name, :active |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer the new style validations validates :column, presence: value
over validates_presence_of
.
Going to solve #35
removede-activate users