-
Notifications
You must be signed in to change notification settings - Fork 0
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
187434149 flow to create user #42
Conversation
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.
Looks good to me.
|
||
# Relationship with LmsCredential | ||
# Associasions |
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.
Associations
has_many :lms_credentials, dependent: :destroy | ||
has_many :user_to_courses |
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.
this is a strange variable/class name, and isn't plural (which i'd expect for has_many). do you mean something like course_specific_users
? it's worth taking time to think carefully about names, as once they are committed you're generally stuck with them
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.
lgtm, couple of minor comments inline.
it 'creates the user successfully' do | ||
post :create, params: { email: '[email protected]' } | ||
|
||
expect(response).to have_http_status(:created) |
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.
this is nitpicking but: technically you should proabbly put the post
in a before :each
block and have the 3 expectations be separate specs, since each spec is supposed to test only 1 behavior
General Info
Changes
Explain your changes here (in such a way that you would understand why you made them a year from now).
I set up the create user flow along with rspec test
Testing
Explain how you tested your changes. If testing is not necessary, explain why.
Documentation
Does this PR require documentation. If so, explain where it can be found.
Checklist