require 'test_helper'

class SessionsControllerTest < ActionController::TestCase
	setup do
		@user = users(:one)
	end

	# This test keeps redirectint you to Login, your credentials aren't 
	# working, possibly password digest problem
	#
	# test "create the users sessions and redirects" do
	#   	post :create, id: @user.id, password_digest: @user.password_digest
	# 	set_current_user(@user)
	#     assert_redirected_to user_path(@user)
 	#   end


	test "destroy the users sessions and redirects" do
	  	delete :destroy, id: @user.id
	    assert_redirected_to login_path
   	end
end
