-
Notifications
You must be signed in to change notification settings - Fork 43
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
Ports - Myriam #18
base: master
Are you sure you want to change the base?
Ports - Myriam #18
Conversation
MediaRanker RevistedWhat We're Looking For
|
@@ -35,12 +35,14 @@ | |||
|
|||
describe "index" do | |||
it "succeeds when there are works" do | |||
perform_login |
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.
One problem with these tests is that you don't have a set of tests for guest users. So you don't have tests that assure that guest users can't do specific things like view a show page, or delete a work.
expect(session[:user_id]).must_equal user.id | ||
end | ||
|
||
it "will not login and redirect to root path if not comming from GitHub" do |
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.
👍
must_respond_with :found | ||
end | ||
|
||
it "will display a flash message if no user is logged in" do |
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,6 +1,9 @@ | |||
class WorksController < ApplicationController | |||
# We should always be able to tell what category | |||
# of work we're dealing with | |||
# before_action :require_login, only: [:new, :create, :edit, :update, :retired] | |||
before_action :require_login, except: [:root, :upvote] #modify upvote |
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.
👍
MediaRanker Revisited
Congratulations! You're submitting your assignment!
Comprehension Questions